46

Gnome-shell seems to like to leave one monitor as "fixed" when you switch workspaces.

Additionally, there is no preview in the Activities view of my secondary monitor.

Also, on the second monitor, where there should be either empty desktop space, or a copy of the panel, I just have a white bar.

How can I get gnome-shell to treat my secondary monitor like the primary one?

David Foerster
  • 36,264
  • 56
  • 94
  • 147
Alex
  • 2,044

8 Answers8

18

14.04

In later versions of Gnome, you have to open gnome-tweak-tool and, under "Workspaces", change the "Workspaces only on primary display" setting.

Amandasaurus
  • 1,816
14

I could not find the /desktop/gnome/shell/windows key mentioned by Martin, but the source he's quoting says to run:

$ gsettings set org.gnome.shell.overrides workspaces-only-on-primary false

This fixed it instantly for me. Thanks, gregcor (the source).

ringe
  • 261
13

Setting workspaces-only-on-primary false (using gsetting, gconftool, GNOME Tweak or whatever – see all other answers) only solves the first problem:

Gnome-shell seems to like to leave one monitor as "fixed" when you switch workspaces.

For the second problem

Additionally, there is no preview in the Activities view of my secondary monitor.

there is a GNOME extension called Multi Monitors Add-On that Just Works™. (See also How do I install and manage GNOME Shell extensions?)

  • 1
    This solution provides the final piece of the puzzle. The other answers all address having workspace behaviour on secondary monitors, but not having the preview of both in activities view. Thanks for solving my 7 year old problem. :) – Alex Mar 15 '19 at 01:16
  • 1
    glad I could help :) – törzsmókus Mar 18 '19 at 10:21
13

Regarding the fixed second monitor, there's an easy way to fix that as I have just found out. If I may quote:

  1. Download gconf-editor – this is probably available in your distribution’s package manager.
  2. Start gconf-editor – the “Run Command” menu is still available in GNOME 3 by pressing Alt-F2.
  3. In the tree on the left, navigate to /desktop/gnome/shell/windows
  4. UNCHECK the box next to workspaces_only_on_primary

Source: http://gregcor.com/2011/05/07/fix-dual-monitors-in-gnome-3-aka-my-workspaces-are-broken/

  • 1
    Thanks for that! That solves the problem in terms of switching workspace with the keyboard, but in the activities view the second monitor shows windows from the second monitor of all workspaces. Hopefully they work on multi monitor support in the future. – Alex Nov 05 '11 at 01:58
  • 2
    See other answers ... this solution is depreciated. – Stephen McAteer Jul 14 '17 at 01:17
  • 1
    Confirmed this is deprecated in 18.04.1 LTS. See https://askubuntu.com/a/1086531/340383 – bgoodr Oct 23 '18 at 20:53
  • @Alex for the Activities problem, see https://askubuntu.com/a/1125322/16985 – törzsmókus Mar 13 '19 at 13:41
4

You can do this by installing GNOME Tweaks from Ubuntu Software. After installation, it shows in apps drawer as Tweaks. The package name is actually called gnome-tweak-tool.

The option you are looking for is located in the Workspaces tab, and it is called Workspaces span displays.

David Foerster
  • 36,264
  • 56
  • 94
  • 147
philsf
  • 854
1

My ubuntu 18.04 with unity has the same problem.
Using the gconf-editor suggested by Martin, the box I need to uncheck located at /org/gnome/mutter/workspaces-only-on-primary.

HD189733b
  • 473
1

18.04.1 LTS

https://askubuntu.com/a/393355/340383 is the correct answer. Posting this to warn others of what seems to me to be a bug:

Adding a checkbox beside Workspaces span displays inside the tweak tool has no effect:

broken workspaces tweaks window

I also could not find a /desktop/gnome/shell key shown by gconf-editor as indicated by the https://askubuntu.com/a/393355/340383 answer.

Update 2019-03-22 07:03: Please also read the commentary for this answer, as the "does NOT have any effect at all" in the picture above may be invalid with subsequent releases after 18.04.1 LTS, and that I've not retried the setting since I posted this answer.

bgoodr
  • 1,562
  • 3
  • 20
  • 34
  • what do you mean by no effect? it solves one of the two problems by OP, at least on 18.04.2 LTS – törzsmókus Mar 13 '19 at 13:42
  • "it solves" is ambiguous. Please specify which of the answers you are referring to that solves the problem. And I do not see that the OP has marked any of the answers as the correct answer yet. – bgoodr Mar 14 '19 at 13:58
  • 1
    I was referring to the action (changing the Display Handling setting to Workspaces span displays, mentioned by multiple answers above) that you claim to “NOT have any effect” at all. Contrary to your claim stated in red, it indeed solves the first half of the problem in the question (leave one monitor as "fixed"). for the second half (there is no preview in the Activities view), see https://askubuntu.com/a/1125322/16985 – törzsmókus Mar 18 '19 at 11:19
  • Your criticism is logged against my saying "does NOT have any effect at all" since I didn't clarify what I observed there in text or in pictures. Duly noted. Unfortunately, my system has likely undergone an upgrade from "18.04.1 LTS" by this point in Mar 22 2019, so I would be hard pressed to correct my notes. Do note that my primary goal with this answer was to warn people about what I consider a bug in GNOME, and to indicate what worked for me in "18.04.1 LTS" (that may actually have been recified in subsequent releases). – bgoodr Mar 22 '19 at 14:00
  • 1
    I added Update 2019-03-22 07:03 to warn others about the information being "stale". – bgoodr Mar 22 '19 at 14:04
  • 1
    Oh, I have not noticed the version difference. That makes sense. Thanks for the edit. – törzsmókus Mar 22 '19 at 14:04
0

found another nice solution where both monitors have separate workspaces:

git clone git://github.com/spin83/multi-monitors-add-on.git
cd multi-monitors-add-on
git branch -a && git checkout gnome-3-32_3-36
cp -r multi-monitors-add-on@spin83 ~/.local/share/gnome-shell/extensions/

alt + F2 type in r then enter

then, you can open your tweaks application on Ubuntu, described above and find there extensions and activate multi-monitors add-on if it's not already activated.

Note: I struggled with error where extension could not have been properly loaded due to errors, you can debug them by reading journal log output:

sudo journalctl /usr/bin/gnome-shell

if that's the case try switching the branch in repository above

or report the error to the owner on GitHub

https://github.com/spin83/multi-monitors-add-on.git

Good luck everybody :)