Skip to content

Conversation

ThomasAdam
Copy link
Member

@ThomasAdam ThomasAdam commented Jan 20, 2023

When interpreting geometry strings, fvwm has an extension to specify a screen name, such as:

100x100+2+90@HDMI-1

This would therefore make the window appear at position 100x100+2+90 relative to monitor HDMI-1.

Normal X11 geometry strings do not have this monitor specifier -- and in such cases, that geometry should be interpreted relative to the position of all the screens, which is called the global screen.

Without this change in this PR, the geometry was relative to the current screen which is confusing.

Fixes #813
Fixes #810

@ThomasAdam ThomasAdam added the type:breaking Issue is not backwards-compatible and will break configs/build label Jan 20, 2023
@ThomasAdam ThomasAdam added this to the 1.0.7 milestone Jan 20, 2023
@ThomasAdam ThomasAdam self-assigned this Jan 20, 2023
@ThomasAdam ThomasAdam changed the title Use the gloal screen for geometry strings which don't specify a monitor Use the global screen for geometry strings which don't specify a monitor Jan 20, 2023
When setting FvwmIconMan's ManagerGeometry string, the caller was using
FScreenParseGeometryWithScreen, which throws away the geometry string
when no screen is specified.

Callers of this function are a holdover from introducing Xinerama, and
hasn't fared any better when RandR replaces Xinerama.

Calling FScreenParseGeometry instead makes the parsing of the geometry
string, and this is what other modules -- such as FvwmButtons is doing.

In doing so, the logic for how screens were being handled was broken.
Rather than assume the PRIMARY screen before checking if we have a
geometry string, remove that and let the geometry string override
anything else.  If one isn't supplied, use the existing logic.

Fixes #813
When a user uses a geometry string without fvwm's extension, ensure that
geometry is interpreted relative to the global screen.

This means that the following string:

    100x100+90+2

... will position itself relative from the position of all screens,
rather than the monitor which is the active one.

Fixes #813
When looking up the global monitor, do so via its helper function.

Fixes #813
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:breaking Issue is not backwards-compatible and will break configs/build
Projects
Status: Done
1 participant