You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On Linux/X11, fit_bounds() gets the workarea from the _NET_WORKAREA property of the root window, which it looks like includes the workarea of all monitors/screens (because the property doesn't depend on a specific screen). I think here is the issue in our case, we should get the workarea of one specific screen in this case (as it does on Windows and macOS).
With the introduction of the Xinerama extension in X11 R6.4, maximization has become more involved. Xinerama allows a screen to span multiple monitors in a freely configurable geometry. In such a setting, maximizing a window would ideally not grow it to fill the whole screen, but only the monitor it is shown on.
dacap
changed the title
Fix _NET_WORKAREA to get given screen workarea
Get desktop workarea correctly on Linux (we cannot use _NET_WORKAREA)
Jan 6, 2022
Use Xrandr's XRRGetMonitors function to find find the position,
bounds, and "main screen" status of all monitors.
On X11, there is no supported method to find the workarea of a monitor.
This includes the _NET_WORKAREA atom, which breaks multi-monitor
setups. This may not be an issue as most window managers aggressively
and correctly enforce their, albeit private, workarea for windows.
This should be a fix for this issue, the details are quoted here:
This issue was previously an item of #2777
Basically we want to get the area that will be used if we maximize the current window in its own screen. From https://specifications.freedesktop.org/wm-spec/wm-spec-1.3.html#idm45682922243328 we can find:
https://www.x.org/releases/X11R7.5/doc/man/man3/Xinerama.3.html
The text was updated successfully, but these errors were encountered: