Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Output scale affects cursor movement between outputs #3529

Closed
jpgrayson opened this issue Jan 28, 2019 · 4 comments
Closed

Output scale affects cursor movement between outputs #3529

jpgrayson opened this issue Jan 28, 2019 · 4 comments

Comments

@jpgrayson
Copy link
Contributor

In my two-output configuration, using scale factors other than 1.00 can cause cursor movement between outputs to be disabled, i.e. cursor movement will stop at the edge of the current output instead of moving to the adjacent output.

My output configuration (with scale factors of 1.00):

Output eDP-1 'Sharp Corporation 0x144A 0x00000000'
  Current mode: 3200x1800 @ 59.981998 Hz
  Position: 0,0
  Scale factor: 1.000000
  Transform: normal
  Workspace: 2
  Available modes:
    3200x1800 @ 47.985001 Hz
    3200x1800 @ 59.981998 Hz

Output DP-1 'Goldstar Company Ltd LG HDR 4K 0x00004F99' (focused)
  Current mode: 3840x2160 @ 59.997002 Hz
  Position: 3200,0
  Scale factor: 1.000000
  Transform: normal
  Workspace: 1
  Available modes:
    640x480 @ 59.939999 Hz
    ...
    3840x2160 @ 59.997002 Hz

Changing the scale of eDP-1 (the left output) to any non-1.0 value will trigger the bug (e.g. swaymsg 'output eDP-1 scale 2').

Using a non-1.0 scale on DP-1 (the right output) does not trigger the bug--the cursor still freely moves between outputs.

If the relative postions of eDP-1 and DP-1 are swapped such that eDP-1 is on the right and DP-1 is on the left (swaymsg 'output eDP-1 position 3200 0; output DP-1 position 0 0;'), then using a non-1.0 scale on DP-1 (now the left output) triggers the bug. I.e. it seems as if the scale of the left output determines whether this bug manifests.

If the outputs' relative positions are modified such that they have an above/below relationship instead of left-of/right-of, using a non-1.0 scale on either output causes the bug to manifest.

Some other notes:

  • Even if the outputs' scales match (e.g. 2.0 and 2.0), the cursor movement is restricted. I.e. it seems to only matter whether the scale is != 1.0.
  • sway version 1.0-beta.2-283-g7c27d73b (Jan 28 2019, branch 'master')
  • wlroots-git 0.2.r178.g018727b1-1
@emersion
Copy link
Member

If the left output has scale 2 and is 3200px wide, you need to position the other one at 3200 / 2 = 1600. Patches welcome to improve the docs if it's not clear enough.

@jpgrayson
Copy link
Contributor Author

Thank you @emersion and apologies for not seeing this in the manuals--it was indeed right there!

I will submit a PR that adds one line to sway-output.5.scd that talks about the cursor only being able to move between immediately adjacent outputs.

@progandy
Copy link
Contributor

progandy commented Jan 28, 2019

It would be great if output positions could be defined in relation to each other (e.g. left-of, below, ...) and sway then calculates the optimal coordinates.

jpgrayson added a commit to jpgrayson/sway that referenced this issue Jan 28, 2019
Add a sentence to sway-output.5.scd to highlight that the cursor can
only be moved between immediately adjacent outputs.

References issue swaywm#3529

Signed-off-by: Peter Grayson <[email protected]>
RedSoxFan pushed a commit that referenced this issue Jan 29, 2019
Add a sentence to sway-output.5.scd to highlight that the cursor can
only be moved between immediately adjacent outputs.

References issue #3529

Signed-off-by: Peter Grayson <[email protected]>
@RedSoxFan
Copy link
Member

@progandy, that could probably be tacked onto #1666.

Either way, this specific issue has been resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

4 participants