! 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 !
custom Application Shortcuts ignored while focus is at :0.1
Status:
RESOLVED: MOVED
Product:
Xfce4-settings
Component:
Xfsettingsd

Comments

Description Rob Couto 2019-11-17 05:40:14 CET
I use two graphics cards, two monitors, and two active X11 Screens. I set a KB shortcut "Super+F1" to run a command, bin/subscreen.sh:

#!/bin/bash
export DISPLAY=:0.1
exec xterm 

The xterm window appears on the second monitor and is immediately given focus (I keep the 'focus new windows' switch on). I can use it to launch more programs whose windows naturally appear on the same monitor, and I can Alt+Tab between them, also only on that screen & monitor. 

The symptom is that no matter how many times I press the key combination, I only get the first xterm unless I click the mouse (still on :0.0) to return the focus (and again each time I want a shortcut to work). I also made a one to launch mouse-switchscreen [1] which "teleports" the mouse pointer between the 2 screens, as these are disconnected (not adjacent) in the server layout. This shortcut only works in one direction, only while anything on :0.0 has focus. After using it, in order to get the pointer back to :0.0, I have to run the command manually in that xterm (or a text console on other vt, or via SSH, using DISPLAY=:0.1 mouse-switchscreen). 

Since it uses the current value for DISPLAY to derive which screen it will switch *to*, making that particular program work "normally" with that shortcut would also require changing the environment handed down to each launched application so that DISPLAY matched whichever screen had focus when the key combination was registered. While that's admittedly a very specific corner case, it seems appropriate to have newly launched applications be placed on the "current" screen in the same way, or for the option to be available-- which of course any command or launcher can still override, just as I did for xterm.

Steps to Reproduce:
- In Window Manager settings, Focus tab, enable "Click to Focus" and  "Automatically give focus to newly created windows"
- configure 2 separate X screens and restart machine (or just display manager)
- run "DISPLAY=:0.1 <any-GUI-program>", taking the focus to 2nd screen
- attempt to use any Application Shortcut, e.g. Alt+F2 for Application Finder

Actual results:
- none

Expected results:
- window for application bound to the shortcut opens on 2nd X screen

OS: Gentoo (unstable ~amd64), kernel: gentoo-sources-5.3.11
HW: Athlon FX-8320, Nvidia GeForce GTX 780  and GeForce GTX 1050 Ti, official binary driver version 440.31, USB mouse & keyboard

[1] https://de.mcbf.net/david/dualscreenmouseutils/
Comment 1 Rob Couto 2019-11-19 11:08:02 CET
Created attachment 9264 
xorg.conf generated by nvidia-settings

(was sure I attached this...)
Comment 2 Git Bot editbugs 2020-05-28 23:15:48 CEST
-- GitLab Migration Automatic Message --

This bug has been migrated to xfce.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.xfce.org/xfce/xfce4-settings/-/issues/151.

Please create an account or use an existing account on one of our supported OAuth providers. 

If you want to fork to submit patches and merge requests please continue reading here: https://docs.xfce.org/contribute/dev/git/start#gitlab_forks_and_merge_requests

Also feel free to reach out to us on the mailing list https://mail.xfce.org/mailman/listinfo/xfce4-dev

Bug #16192

Reported by:
Rob Couto
Reported on: 2019-11-17
Last modified on: 2020-05-28

People

Assignee:
Xfce Bug Triage
CC List:
1 user

Version

Version:
4.14.1

Attachments

xorg.conf generated by nvidia-settings (3.01 KB, text/plain)
2019-11-19 11:08 CET , Rob Couto
no flags

Additional information