XRandr reconfiguration reshuffles windows even if not needed (since icewm 3.3.3)
Closed this issue · 8 comments
Something like xrandr --output DisplayPort-1 --same-as DisplayPort-0 --auto
doesn't change the resolution or desktop size, but it moves around and reorders all windows on the current workspace. Windows in other workspaces are not changed. Tested in icewm 3.3.3. I suspect this is caused by the fix to #713.
This is really inconvenient. I don't want icewm to shuffle my windows even if the screen or desktop resolution changes. Would it be possible to add an option that disables the window moving code? (It should still move the taskbar.)
Setting ArrangeWindowsOnScreenSizeChange=0
helps immediately.
If you say that the taskbar should be moved, do you mean that the position of the output has changed? Doesn't --same-as
preserve geometries?
Could you give the output of xrandr -q
before and after that command?
Setting
ArrangeWindowsOnScreenSizeChange=0
helps immediately.
Perfect. This solves the problem for me.
Could you give the output of
xrandr -q
before and after that command?
Before:
Screen 0: minimum 320 x 200, current 3840 x 2160, maximum 16384 x 16384
DisplayPort-0 connected primary 3840x2160+0+0 (normal left inverted right x axis y axis) 600mm x 340mm
3840x2160 60.00*+ 30.00
2560x1440 59.95
1920x1200 60.00
1920x1080 60.00 59.94
1600x1200 60.00
1680x1050 60.00
1600x900 60.00
1280x1024 60.02
1440x900 60.00
1280x800 59.81
1280x720 60.00 59.94
1024x768 60.00
800x600 60.32
720x480 60.00 59.94
640x480 60.00 59.94
DisplayPort-1 connected (normal left inverted right x axis y axis)
3840x2160 60.00 + 60.00 59.94 60.00 30.00 25.00 24.00 29.97 23.98
1920x2160 60.00
2560x1440 59.95
2048x1152 60.00
1920x1200 59.88
1920x1080 60.00 60.00 50.00 59.94
1600x1200 60.00
1680x1050 59.95
1600x900 60.00
1280x1024 60.02
1440x900 60.00
1280x800 59.81
1280x720 60.00 50.00 59.94
1024x768 60.00
800x600 60.32 56.25
720x576 50.00
720x480 60.00 59.94
640x480 60.00 59.94
HDMI-A-0 disconnected (normal left inverted right x axis y axis)
HDMI-A-1 disconnected (normal left inverted right x axis y axis)
DVI-D-0 disconnected (normal left inverted right x axis y axis)`
Command:
xrandr --output DisplayPort-1 --same-as DisplayPort-0 --auto
After:
Screen 0: minimum 320 x 200, current 3840 x 2160, maximum 16384 x 16384
DisplayPort-0 connected primary 3840x2160+0+0 (normal left inverted right x axis y axis) 600mm x 340mm
3840x2160 60.00*+ 30.00
2560x1440 59.95
1920x1200 60.00
1920x1080 60.00 59.94
1600x1200 60.00
1680x1050 60.00
1600x900 60.00
1280x1024 60.02
1440x900 60.00
1280x800 59.81
1280x720 60.00 59.94
1024x768 60.00
800x600 60.32
720x480 60.00 59.94
640x480 60.00 59.94
DisplayPort-1 connected 3840x2160+0+0 (normal left inverted right x axis y axis) 698mm x 393mm
3840x2160 60.00*+ 60.00 59.94 60.00 30.00 25.00 24.00 29.97 23.98
1920x2160 60.00
2560x1440 59.95
2048x1152 60.00
1920x1200 59.88
1920x1080 60.00 60.00 50.00 59.94
1600x1200 60.00
1680x1050 59.95
1600x900 60.00
1280x1024 60.02
1440x900 60.00
1280x800 59.81
1280x720 60.00 50.00 59.94
1024x768 60.00
800x600 60.32 56.25
720x576 50.00
720x480 60.00 59.94
640x480 60.00 59.94
HDMI-A-0 disconnected (normal left inverted right x axis y axis)
HDMI-A-1 disconnected (normal left inverted right x axis y axis)
DVI-D-0 disconnected (normal left inverted right x axis y axis)
If you say that the taskbar should be moved, do you mean that the position of the output has changed? Doesn't
--same-as
preserve geometries?
Almost forgot about this. I just mean in general. In the case I reported, position or resolution don't change. But if they change, I would expect that the taskbar gets moved.
Can you test this (with ArrangeWindowsOnScreenSizeChange=1)?
Can you test this (with ArrangeWindowsOnScreenSizeChange=1)?
I can confirm that this doesn't reshuffle the windows anymore in my test case.
I suggest the following changes to the window rearrangement code:
- move windows only if the upper left corner is outside of the usable desktop area
- do this on all workspaces