You are not logged in.
Pages: 1
Hey,
I'm trying to do some manual window positioning. I've found the workspace margins in xfconf-query -c xfwm4 -p /general/margin_*
But this doesn't account for panels. Is there some way to get an absolute usable desktop area?
Cheers,
Michael
Offline
Actually, xfdesktop tracks this for it's icon placement. You can find the usable desktop space in ~/.config/xfce4/desktop. Locate the latest .rc file and the usable geometry will be in the filename:
$ ls -lt | sed -n '2p'
-rw-r--r-- 1 toz toz 201 Jan 16 07:07 icons.screen0-1366x745.rc
Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki | Community | Contribute ---
Offline
Awesome. Thanks ToZ!
In case anyone else winds up here the full line is now:
$ ls -t $HOME/.config/xfce4/desktop | head -n 1 | cut -d "-" -f 2 | cut -d "." -f 1
1350x725
Last edited by michja (2019-01-18 20:25:48)
Offline
Looks like I spoke too soon. That number isn't right. I'm missing 16px from the margins somewhere. Any ideas?
$ls -t $HOME/.config/xfce4/desktop | head -n 1 | cut -d "-" -f 2 | cut -d "." -f 1
1350x725
$ xdpyinfo | awk '/dimensions/{print $2}' | cut -d "x" -f1
1366
$ xfconf-query -c xfwm4 -p /general/margin_left
16
$ xfconf-query -c xfwm4 -p /general/margin_right
16
Offline
Looks like it doesn't take into account the margins. Maybe you could use both pieces of information to get the "real" available space?
Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki | Community | Contribute ---
Offline
The problem is reliably knowing where the usable area begins and ends if it could be defined by a margin or a panel height at the top or bottom of the screen. But if there isn't an easy place to check then I don't need to know that badly.
I can set the margins to overlap my panels exactly, Use those values & provide override parameters. And probably never have to worry about it again
Offline
The window manager calculates this space by taking the current page minus space occupied by dock and panel windows.
You can find it in root window's property _NET_WORKAREA.
xprop -root _NET_WORKAREA
The output is printed like this x, y, width, height
where x, y is the top left corner.
If you have several workspaces those will be in the output as well.
https://specifications.freedesktop.org/ … ETWORKAREA
For reserved space for panels check _NET_WM_STRUT or _NET_WM_STRUT_PARTIAL properties of the panel windows.
https://specifications.freedesktop.org/ … NETWMSTRUT
Do you want to exit the Circus?
https://www.youtube.com/watch?v=ZJwQicZHp_c
Offline
Cheers Misko.
The combination of STRUT_PARTIAL and xfconf general/margin is perfect. Between them that's all the info needed
Offline
Pages: 1
[ Generated in 0.014 seconds, 8 queries executed - Memory usage: 545.45 KiB (Peak: 546.3 KiB) ]