Ask Your Question
4

Steal focus not working?

asked 2017-10-10 04:49:09 -0600

alfC gravatar image

updated 2018-03-13 22:54:21 -0600

In the last Fedora (26) distribution I notice a change in behavior of Gnome. When I double click in Files on a file that is already opened (for example a PDF), nothing happens. Of course I have to figure out that the reason is that the window was already open in the background.

However, I don't receive any notification or clue of what is going on.

This happens in other context, when relaunching a program, or opening text files, either from Files or from the command line in terminal window.

In Gnome Tweaks, there is an option called "Automatically Raise Windows", but it doesn't seem to make a difference. I have all the plugins switched off.


I reinstalled the system from scracth (Fedora 27) and it seems that the problem persists, so it is the default. This is very anoying because I cannot lift windows by executing commands from the terminal (e.g. evince or gedit) or by double clicking in Nautilus if the window is already open. The behavior is that, if the window already exists, it is left in the background and one cannot see anything happening in the screen.


These are the steps to reproduce the problem:

  1. Open a Terminal
  2. Execute nautilus . (a new window will open in the front)
  3. Go back to the Terminal (with the mouse or with Alt-Tab)
  4. Execute nautilus . (nothing will happen, the old window is not raised to the top).

This is very confusing, I don't mind reusing the old window or even opening a redundant one, but the current behavior is very confusing, specially for someone used to control gedit from the command line. I wonder if this is a problem with Gnome only. XFCE might not have this problem.

edit retag flag offensive close merge delete

Comments

Using Fedora 27, I can't reproduce your problem (...desktop.wm.preferences auto-raise reads false)

florian gravatar imageflorian ( 2018-03-13 22:58:53 -0600 )edit

@florian I don't know, I installed from scratch and the problem continued. I now installed https://extensions.gnome.org/extensio... but didn't help.

alfC gravatar imagealfC ( 2018-03-13 23:10:11 -0600 )edit

@florian , so, does running nautilus . twice brings the window to the front?

alfC gravatar imagealfC ( 2018-03-13 23:11:53 -0600 )edit

Yes it does. (Ah, and yes, I realized I have that extension installed as well).

florian gravatar imageflorian ( 2018-03-13 23:24:38 -0600 )edit

Ahrrr, but not even with the extension works for me. The extension doesn't have options. The extension was create a few version of fedora ago to avoid the annoying not focus + "your window is ready" message. But now it is the worst since nothing happens after running a command.

alfC gravatar imagealfC ( 2018-03-13 23:29:13 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
4

answered 2018-02-16 04:02:00 -0600

alfC gravatar image

updated 2018-10-09 20:38:09 -0600

UPDATE 2: The only reliable way I found so far was to turn off Wayland and go back to Xorg. (Fedora 28, Gnome 3.28.3


UPDATE 1: I am confused: This stopping working or I didn't test it well.


I found the solution here: https://superuser.com/a/1133557/68715

It was kind of obvious in perspective: dconf-editor -> Desktop>wm>preferences>auto-raise to ON

edit flag offensive delete link more

Comments

You don't need no dconf-editor:

Read:

gsettings get org.gnome.desktop.wm.preferences auto-raise

Write

gsettings set org.gnome.desktop.wm.preferences auto-raise true
florian gravatar imageflorian ( 2018-03-13 22:55:50 -0600 )edit
2

This is a known bug in Gtk+ on Wayland, see https://gitlab.gnome.org/GNOME/gtk/is... for details.

genodeftest gravatar imagegenodeftest ( 2018-10-10 02:38:21 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2017-10-10 04:49:09 -0600

Seen: 937 times

Last updated: Oct 09