Hi, I’m new to qubes and I’ve gone through some discussions and made qubes more keyboard friendly using scripts… Now it would be handy if I could move the window in focus between monitors… Has anyone done it yet or can anyone help me with it…?
I think the challenge here is to figure out “which monitor the window is on”…
System Settings → Windows Manager → Move window to left/right workspace
Workspaces are not the same as monitors, though…I don’t think there’s a readily available Xfce mechanism to move a window onto a different monitor (if used in expand mode), but you could write a script that makes use of xdotool windowmove x y
(see man xdotool
in dom0) to achieve this for your default setup.
To get the window’s current coordinates use xdotool getwindowgeometry --shell windowID
, which will store x and y coordinates in $X
and $Y
automatically. You can get the windowID of the window in focus by executing xdotool getwindowfocus
in the same script.
You can use wmctrl and xdotool to do it, you use window=$(printf '0x0%x' $(xdotool getwindowfocus))
to get the focused window, and then you move it with wmctrl.
Here is some info on how to work with the window
https://forum.qubes-os.org/t/controlling-xfce-windows-with-wmctrl/22299
https://forum.qubes-os.org/t/tiling-xfce-windows-with-shortcut-keys/22840
Thanks…
xdotool windowmove
is indeed what I’ve been looking for …