87

Is there a way to the switch gnome-shell window buttons to the left? I've gotten so used to them being on the left that them being on the right has thrown me way off.

(gnome shell has them defaulted to the right corner)

muru
  • 207,228
Noel
  • 1,862

11 Answers11

71

For Ubuntu 12.04 and newer

You will need dconf-editor, which is part of the dconf-tools package. Install it first:

dconf-tools

Start dconf-editor:

Alt+F2 → dconf-editor

Go to org → gnome → shell → overrides → button layout. Change it to close,minimize,maximize:

No need to restart the shell.

Note: This also changes the cancel button in the overlay mode.

For 13.10 and higher

As per a few users, it may require a shell restart. Thank you all for pointing that out.

For 15.10 and higher

The schema is now org.gnome.desktop.wm.preferences as per this comment.

Pieter
  • 213
Ubuntuser
  • 10,012
63

While technically not gnome-shell, if you're using gnome-flashback or gnome-flashback-no-effects the key is located at:

org -> gnome -> desktop -> wm -> preferences -> button-layout  

Changing it to:

close,minimize,maximize:  

should give you what you want.

You can use the command:

gsettings set  org.gnome.desktop.wm.preferences button-layout 'close,minimize,maximize:'

to get this done quicker.

Seth
  • 59,332
31

For 10.10

The more simple way to do that is: Alt+F2gconf-editor

Navigate to apps → metacity → general, and double click on the entry: button_layout, then enter close,minimize,maximize:. You can also use spacer at some point to add a space.

For 11.04 and 11.10

Alt+F2gconf-editor

Navigate to desktop → gnome → shell → windows, and double click on the entry: button_layout, then enter close,minimize,maximize:. You can also use spacer at some point to add a space.

fossfreedom
  • 174,526
RolandiXor
  • 51,797
20

If you're using Gnome Shell and you want the window buttons on the left, use this command:

dconf write /org/gnome/shell/overrides/button-layout "'close,minimize,maximize:'"

Then restart the shell if needed: press Alt+F2, type r and press Enter.

regan
  • 754
14

If you have installed Ubuntu Tweak, go to Window Manager and change the Place from left to right or vice versa. This will change all windows' Titlebar button layout, not only gnome shell.

alt text

Vassilis
  • 2,957
10

Gnome version 3.10, Using 13.04 and 13.10

If you upgrade Gnome to 3.10 you may notice a change in window decorations.
Gnome version 3.10 is moving towards Client Side Decorations(CSD for short) in all of the Core apps.

In these apps the close button is integrated into the program window and does not use the normal window decorations.

enter image description here

As Web Upd8 states:

Another pretty major change in the latest GNOME 3.10 is the introduction of "header bars" or "client side decorations". These decorations use the GTK+ toolkit and theme engine:

As you can see, the close button is now displayed inline with the toolbar which saves spaces but unfortunately it also creates an even bigger discrepancy between GNOME core apps and the other applications, because only the core GNOME apps use these client side decorations.


Some applications that have CSD may respect the environment variable GTK_CSD=0 (a variable used to "try out" CSD in eariler gnome versions with =1) for more information about Environment variables: https://help.ubuntu.com/community/EnvironmentVariables especially the section: Launching desktop application with an environment variable to experiment with programs adding something like this to a launcher:

Exec=env GTK_CSD=# gedit

substuting "#" with 1 or 0 for on and off, and gedit with program of choice

However it seems with Nautilus in 3.10 the variable Does not work.


Simply put:

In 3.10 it's going to have a close button at the top right no matter what[...]


So what can you do?

  • Stay at an older version of Gnome. Development is still progressing and the Gnome version in the repositories works just fine. It may be likely that options will be added in the future.
  • Replace Nautilus with Nemo. Form most cases Nemo looks and acts like Nautilus:

    enter image description here

    To Install:

    1. Open Terminal put the following command:
    2. sudo apt-get install nemo
    3. Make nemo the default file browser
Mateo
  • 8,152
8

In Ubuntu 18.04 and later there are multiple options:

  1. You can now just install GNOME Tweak Tool (which is a helpful tool anyway) from the Software Center or by running in a terminal:

    sudo apt install gnome-tweaks
    

    and in the menu Window Titlebars change Placement to Left.

    Tweaks

  2. Dconf-editor/tool change still works:

    /org/gnome/desktop/wm/preferences/button-layout
    

    set to close,minimize,maximize.

  3. And the terminal option, too:

    gsettings set  org.gnome.desktop.wm.preferences button-layout 'close,minimize,maximize:'
    
Filbuntu
  • 13,891
4

Do what hrhnick said, except use this command instead:

gconftool-2 -s /desktop/gnome/shell/windows/button_layout -t String minimize,maximize,close:" where "minimize,maximize,close:

Then hit Alt+F2 and type

gnome-shell --replace

and hit enter

Kris Harper
  • 13,705
4

The workspace window view of gnome shell uses the same button layout as the window manager (albeit only for the close button). (relevant code)

If you set your close window buttons to the left using gconf, the close button on the window preview in workspace view will also display on the left.

Using gconf-editor, change /desktop/gnome/shell/windows/button_layout to close,minimize,maximize: and re-login to see the change.

4

17.04 and 17.10 (Gnome 3.22)

The beginning is as in this answer: https://askubuntu.com/a/113995/286561

You will need dconf-editor, which is part of the dconf-tools package. Install it first:

dconf-tools

Start dconf-editor:

Alt+F2 → dconf-editor

But the key is /org/gnome/desktop/wm/preferences/button-layout, the default is: appmenu:cloe, I've changed it to close,minimize,maximize:appmenu. (appmenu doesn't seem to have an effect.)

enter image description here

I've you want to do it on the terminal you can do it as pointed out in this answer: https://askubuntu.com/a/377811/286561

gsettings set  org.gnome.desktop.wm.preferences button-layout 'close,minimize,maximize:'
3

This command should work: gconftool-2 --set /apps/metacity/general/button_layout --type string "menu:minimize,maximize,close" (Assuming you want to move them from left to right, which is what I interpreted from your question...assuming move from left to left was a typo :-) ).

Jayson Rowe
  • 1,858