! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
Raise on click - False does not work with Click to Focus
Status:
RESOLVED: FIXED

Comments

Description bjoernbjoernbjoern 2018-09-02 23:13:55 CEST
I have a new installation of Manjaro (17.1.11) with xfce4 included. xfce is of version 4.12 and xfwm4 is of version 4.13.1

The issue is that if I use "Click to focus", the option "click to raise - false" does not work. That is, I want to click in a window to put it in focus, BUT I do not want this action to raise the window, unless I click on the taskbar. That is the behavior I had previously.

Only if I use "mouse hover to focus", can I click inside a window without it being raised.

My exact settings are the following (which work on my other computer running CentOS7 with xfce4 of version 4.12 and xfwm4 of version 4.12.3):

in Window manager:
Focus model - click to focus
Raise window when focused - disabled
Raise on click - disabled

In Window manager (advanced):
Block focus stealing - active
respect ICCCM focus - disabled
When window is raised - do nothing

And in Settings editor I have:
prevent focus stealing - true
rasie on click - false
raise on focus - false
raise with any button - false
Comment 1 bjoernbjoernbjoern 2018-11-01 17:54:36 CET
As a note, downgrading the xfwm4 package to version 4.12.3 is a workaround
( pacman -U https://archive.archlinux.org/packages/x/xfwm4/xfwm4-4.12.3-2-x86_64.pkg.tar.xz )
Comment 2 Jesse Millwood 2019-02-02 18:02:58 CET
This also bugged me when using xfwm4 version 4.13.1-r1 on Gentoo. I have the same settings and can confirm the same behavior
Comment 3 Jesse Millwood 2019-02-02 18:08:31 CET
Actually I tried cycling on and off the focus related options in the window manager and window manager tweak menus and it seems to have fixed it? I also left the respect ICCM focus disabled but also disabled block focus stealing. That may have done it too.
Comment 4 Olivier Fourdan editbugs 2019-02-05 13:27:38 CET
Right that would be  bug, but please note this option cannot work with client side decorations (most gtk3 clients nowadays) simply because, well, the client draws its decorations instead of xfwm4 so I reckon we'd rather remove that option, it's become unreliable (as depending on the client).
Comment 5 Remington Furman 2019-03-25 03:40:07 CET
I also experience this issue on version 4.13.1 in Arch.

I ran a git bisect between tags xfwm4-4.12.3 and xfwm4-4.13.0, and found that the regression was introduced in commit 3877bf45d39928b2ec485945af1fba7a16645c7d "stacking: Raise on focus to activate".  It's a small commit, but unfortunately I don't know the code base at all and don't have time at the moment to investigate further.  Hopefully this pointer helps.  Thanks to Bjoern for pointing out a working version.

I really like this feature, even if it can't work with all apps.
Comment 6 Git Bot editbugs 2019-04-15 22:08:40 CEST
Olivier Fourdan referenced this bugreport in commit 7431908b17d3e75d7f5ac9b55fae2d24194380ca

focus: Raise on activate only with raise-on-focus

https://git.xfce.org/xfce/xfwm4/commit?id=7431908b17d3e75d7f5ac9b55fae2d24194380ca
Comment 7 Olivier Fourdan editbugs 2019-04-15 22:23:31 CEST
That should fix it, but I admit I'm getting more and more confused at the myriad of options in xfwm4 and the side effects of each one may have on the others...
Comment 8 Remington Furman 2019-04-15 23:23:00 CEST
Thanks Oliver.  I don't blame you for getting confused.  I wish I had more time to help sort this out myself.

I tested this with "Raise on focus - Automatically raise windows when they receive focus" off and "Raise on Click - Raise windows when clicking inside application window" off.

Windows now stay in the background when clicked inside application window and they come to the front when window decorations are clicked or with Alt-Tab.  This is the desired behavior.

However, they remain in the background (and just receive focus) when selected from xfce4-panel.  So that is less useful.  I guess that is because they only receive focus from the panel, but since I have "Raise on focus" off they don't raise.  Maybe there's a way for the panel to always raise the window, similar to Alt-Tab?

If I turn on "Automatically raise windows when they receive focus" then the panel works, but clicking inside an application gives the window focus and it raises, regardless of the setting of "Raise on click".

I'd like to think of a way to refactor this logic and maybe rename some of the options.  Maybe a table lookup to define the behavior would be easier to reason about for both users and developers.

Bug #14656

Reported by:
bjoernbjoernbjoern
Reported on: 2018-09-02
Last modified on: 2019-04-15

People

Assignee:
Olivier Fourdan
CC List:
2 users

Version

Version:
4.13.1

Attachments

Additional information