Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Disable Minimize Animation in Gnome 2.4
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
geders
Tux's lil' helper
Tux's lil' helper


Joined: 19 Jun 2002
Posts: 76
Location: Purdue

PostPosted: Wed Dec 10, 2003 3:49 pm    Post subject: Disable Minimize Animation in Gnome 2.4 Reply with quote

Ok, when you minimize a window under Gnome, it gives you a "cool animation" which is slow, ugly, and not my cup of tea.

Here's how I disabled it (kind of MacGuyver style, but whatever):
Code:

[/home/geders ]$ su
Password:
bash-2.05b# emerge metacity
Calculating dependencies ...done!
>>> emerge (1 of 1) x11-wm/metacity-2.6.2 to /
>>> md5 src_uri ;-) metacity-2.6.2.tar.bz2
>>> Unpacking source...
>>> Unpacking metacity-2.6.2.tar.bz2 to /var/tmp/portage/metacity-2.6.2/work
>>> Source unpacked.


!!! NOW HIT CTRL-Z to suspend emerge temporarily !!!
You need to make sure you hit Ctrl-Z anytime after it says Source unpacked and before it begins compiling window.c.

Now edit the file src/window.c under the work directory:

Code:

vi /var/tmp/portage/metacity-2.6.2/work/metacity-2.6.2/src/window.c


On line 1254 you'll see the following code:
Code:
          /* Draw a nice cool animation */
          meta_effects_draw_box_animation (window->screen,
                                           &window_rect,
                                           &icon_rect,
                                           META_MINIMIZE_ANIMATION_LENGTH,
                                           META_BOX_ANIM_SCALE);


Just comment this out, so make it look like this:
Code:
          /* Draw a nice cool animation */
//          meta_effects_draw_box_animation (window->screen,
//                                           &window_rect,
//                                           &icon_rect,
//                                           META_MINIMIZE_ANIMATION_LENGTH,
//                                           META_BOX_ANIM_SCALE);


Now save your changes, and let emerge continue compilation with the "fg" command:
Code:
bash-2.05b# fg
emerge metacity
 * Working directory: /var/tmp/portage/metacity-2.6.2/work/metacity-2.6.2...
 * Applying libtool-tmp.patch...
 * Applying libtool-sed.patch...
 * Applying libtool-portage.patch...
configure: WARNING: If you wanted to set the --build type, don't use --host.
    If a cross compiler is detected then cross compile mode will be used.
checking for a BSD-compatible install... /bin/install -c
<<blah, blah, blah>>


I noticed that Gnome wigs out if you try to just log out and log back in, so I had to restart (???) after doing this. Anyway, now I have no animation, so everything is faster and looks nicer. You could easily make a patch to do this, but you'd have to edit the ebuilds and then try to get the maintainers to accept it, so this is an easier way. Please note you'll have to do this each time you update metacity, but that's not terribly often.
Back to top
View user's profile Send private message
Bastux
Guru
Guru


Joined: 15 Dec 2002
Posts: 369
Location: France - Paris

PostPosted: Wed Dec 10, 2003 5:37 pm    Post subject: Reply with quote

I loooooove this kind of tricks :) :) :)

I feel like a hacker 8)
Back to top
View user's profile Send private message
tuxlearner
Tux's lil' helper
Tux's lil' helper


Joined: 09 Aug 2003
Posts: 75
Location: Mumbai, India.

PostPosted: Sat Dec 13, 2003 12:39 pm    Post subject: Reply with quote

Bastux wrote:
I loooooove this kind of tricks :) :) :)

I feel like a hacker 8)


LOL :lol:
_________________
In an Open World , who needs Windows and Gates ?
Back to top
View user's profile Send private message
astika
Tux's lil' helper
Tux's lil' helper


Joined: 31 Oct 2003
Posts: 131
Location: /usr/local/src

PostPosted: Sat Dec 13, 2003 8:38 pm    Post subject: Reply with quote

i heart you.

this is the one thing that was bugging me about metacity, i looked high and
low for an option to disable this, and found none. followed the instructions
posted, and no more ugly "cool" animation!

thanks!
Back to top
View user's profile Send private message
grzewho
l33t
l33t


Joined: 31 Dec 2002
Posts: 626
Location: /home/g

PostPosted: Mon Dec 15, 2003 6:14 pm    Post subject: Reply with quote

cool !

how about disabling the awful `fade to black` effect when logging out ?

btw. xscreensaver fades to black nicer than gnome :P
_________________
Code:
USE="freedom -software_patents" emerge --deep --update world
Back to top
View user's profile Send private message
geders
Tux's lil' helper
Tux's lil' helper


Joined: 19 Jun 2002
Posts: 76
Location: Purdue

PostPosted: Mon Dec 15, 2003 10:52 pm    Post subject: Reply with quote

I'm not sure about that fade to black on logout, but does anyone know how to put a "shutdown the computer" icon under the "Actions" menu in Gentoo? I really don't care to drop to GDM and then have to click on something again to get my machine to shut down (its a laptop, so I do power up and down quite often).
Back to top
View user's profile Send private message
geders
Tux's lil' helper
Tux's lil' helper


Joined: 19 Jun 2002
Posts: 76
Location: Purdue

PostPosted: Thu Jan 15, 2004 6:49 pm    Post subject: Reply with quote

Just a bump to let everyone know this works also on metacity 2.6.3 that is used in the Gnome 2.4.1 release...
Back to top
View user's profile Send private message
gärtner
n00b
n00b


Joined: 19 Jun 2003
Posts: 36
Location: Winterthur, Switzerland

PostPosted: Thu Jan 15, 2004 7:22 pm    Post subject: Reply with quote

Quote:
how to put a "shutdown the computer" icon under the "Actions"

If you're using a laptop, you should have a power-off button and when it runs with acpi you can configure it that it shuts down pressing the button.
No more clicking ;-)

Cheers

Gärtner
Back to top
View user's profile Send private message
Ari Rahikkala
Guru
Guru


Joined: 02 Oct 2002
Posts: 370
Location: Finland

PostPosted: Fri Jan 16, 2004 6:16 am    Post subject: Reply with quote

You know, there's no need to use C-Z. Gentoo is designed to (among other things) facilitate changing the source of downloaded programs locally before changing it so there is an official, quite easy way to do it... I'll write out the manual instructions here, then write a patch to do this automatically.

Just for clarity, the ebuild shell command will hereafter be referred to as ebuild(1), while a package in /usr/portage will be called ebuild(5). This is normal notation of man sections. See
Code:
man 1 ebuild
and
Code:
man 5 ebuild
for the difference and
Code:
man man
for an explanation.

cd to /usr/portage. This is so that you don't need to add the path to the beginning of all of those ebuild(5) names. Fetch and unpack the package you want to hack, x11-wm/metacity-2.6.2 here (that's Portage's internal name for the package - the actual ebuild(5) is, relative to /usr/portage, x11-wm/metacity/metacity-2.6.2.ebuild). Use emerge -f if you want to, however, this command will do the whole job:

Code:
ebuild x11-wm/metacity/metacity-2.6.2.ebuild fetch unpack


Now follow geder's instructions about editing the source in the work directory. Then compile the package and do the rest of the stuff required to make it a working part of your system:

Code:
ebuild x11-wm/metacity/metacity-2.6.2.ebuild compile preinst install qmerge postinst

_________________
<laurentius> gentoo linux?
<ari> Yesh.
<laurentius> they look horny
Back to top
View user's profile Send private message
geders
Tux's lil' helper
Tux's lil' helper


Joined: 19 Jun 2002
Posts: 76
Location: Purdue

PostPosted: Fri Jan 16, 2004 6:48 pm    Post subject: Reply with quote

Great ideas, but hitting Ctrl-Z, cd'ing to the directory, making the trivial change, and then hitting fg seems much easier (and intuitive) to me...but this probably helps some people...
Back to top
View user's profile Send private message
astika
Tux's lil' helper
Tux's lil' helper


Joined: 31 Oct 2003
Posts: 131
Location: /usr/local/src

PostPosted: Fri Jan 16, 2004 7:23 pm    Post subject: Reply with quote

geders, i used the same procedure (inspired by your post here) in one of my
own posts here: https://forums.gentoo.org/viewtopic.php?t=121973 :D
_________________
even now in heaven, there were angels carrying savage weapons
Back to top
View user's profile Send private message
ecatmur
Advocate
Advocate


Joined: 20 Oct 2003
Posts: 3595
Location: Edinburgh

PostPosted: Sat Jan 17, 2004 12:19 am    Post subject: Reply with quote

What's wrong with making a patch and adding it to a custom ebuild in /usr/local/portage? I do it all the time, and then you've got a fair chance of being able to reuse it on an update. In fact, you could have posted the patch and ebuild here and saved everyone the trouble of doing it themselves...
Back to top
View user's profile Send private message
ikshaar
Veteran
Veteran


Joined: 23 Jul 2002
Posts: 1339
Location: Baltimore, MD

PostPosted: Thu Jan 22, 2004 4:36 pm    Post subject: Reply with quote

grzewho wrote:
how about disabling the awful `fade to black` effect when logging out ?


Any news on that one ?? .... it's really ugly on my computer and I REALLY want to get rid of it.... :twisted:
_________________
"May God stands between you and harm in all the empty places where you must walk" - Babylon 5
Back to top
View user's profile Send private message
dkaplowitz
Guru
Guru


Joined: 22 Nov 2003
Posts: 596
Location: Philadelphia, PA

PostPosted: Fri Apr 23, 2004 6:11 pm    Post subject: Reply with quote

cooool! Thanks for posting this, geders.

I personally found your ctrl-Z instructions a little too unscientific (and my machine was doing it so fast I wound up interrupting the actual compile), so thankfully Ari Rahikkala's instructions were helpful too.

It's nice to be rid of that lousy animation.
_________________
http://dkap.info
Back to top
View user's profile Send private message
Lycander
Guru
Guru


Joined: 10 Apr 2003
Posts: 468

PostPosted: Fri Apr 23, 2004 8:16 pm    Post subject: Reply with quote

Sorry to be off topic, but someone had asked for a button to shutdown the computer?

Is it feasible to write a script to do:

Code:
init 0
halt


And make a shortcut button to the script? Might have to provide a admin password though.:?
_________________
* Blessing /dev/hda2 with holy penguin pee
Back to top
View user's profile Send private message
ikshaar
Veteran
Veteran


Joined: 23 Jul 2002
Posts: 1339
Location: Baltimore, MD

PostPosted: Fri Apr 23, 2004 8:56 pm    Post subject: Reply with quote

Does that "init 0" will take care of closing your Gnome/KDE/X session correctly ? or is a "brute" way to do it ?
_________________
"May God stands between you and harm in all the empty places where you must walk" - Babylon 5
Back to top
View user's profile Send private message
dkaplowitz
Guru
Guru


Joined: 22 Nov 2003
Posts: 596
Location: Philadelphia, PA

PostPosted: Sat Apr 24, 2004 4:18 am    Post subject: Reply with quote

ikshaar wrote:
Does that "init 0" will take care of closing your Gnome/KDE/X session correctly ? or is a "brute" way to do it ?
I don't think changing the init state is a graceful way to kill your x-session, but I could be wrong. I'd have a look at the script that whichever WM you're using uses for shutting down and make something custom out of that. That or I'd just continue to shut the thing down from the menu.
_________________
http://dkap.info
Back to top
View user's profile Send private message
Lycander
Guru
Guru


Joined: 10 Apr 2003
Posts: 468

PostPosted: Sat Apr 24, 2004 4:38 am    Post subject: Reply with quote

I've seen a init script (System V run level editor) GUI editor in other distros, not sure how to get it in Gentoo. Basically in that tool you can add/remove services/programs to start/stop at those run levels. If xdm is in the list then it will take down your WM for you. Just look at the console text after you log out and selecy Shutdown System. It says "switcing to run level 0". That's how I assume that doing

# init 0

will shutdown the system, followed by the halt command to finish it off. I could be totally wrong about it though.
_________________
* Blessing /dev/hda2 with holy penguin pee
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum