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

Mouse does not work in AppVMs on rotated monitor #3984

Open
davidad opened this Issue Jun 13, 2018 · 2 comments

Comments

Projects
None yet
4 participants
@davidad

davidad commented Jun 13, 2018

Qubes OS version:

R4.0

Affected component(s):

Probably related to qvm-start-gui --notify-monitor-layout


Steps to reproduce the behavior:

  • Install Qubes R4.0
  • Attach an external monitor
  • Rotate the external monitor with xrandr --rotate left
  • Launch Firefox in an AppVM
  • Move Firefox window to external monitor
  • Click inside the Firefox window

Expected behavior:

Firefox responds to mouse activity

Actual behavior:

Firefox does not receive mouse events correctly

General notes:

If I don't rotate, mouse works fine, and xrandr output in the AppVM looks like

Screen 0: minimum 64 x 64, current 7680 x 2160, maximum 32767 x 32767
DUMMY0 connected primary 3840x2160+0+0 325mm x 182mm
   QB3840x2160   23.10*+
DUMMY1 connected 3840x2160+3840+0 650mm x 365mm
   QB3840x2160   23.10*+  23.10* 
   QB2160x3840   59.98  

With rotation:

Screen 0: minimum 64 x 64, current 7680 x 2160, maximum 32767 x 32767
DUMMY0 connected primary 3840x2160+0+0 325mm x 182mm
   QB3840x2160   23.10*+
DUMMY1 connected
   QB3840x2160   23.10 +  23.10  
   QB2160x3840   59.98  

Also, running qvm-start-gui --notify-monitor-layout doesn't seem to have any effect.


Related issues:

#1599 "[3.0] Mouse does not work in AppVMs on second monitor"
Possibly #3897 "Qubes No Longer Recognizes External Monitors"

@o-

This comment has been minimized.

Show comment
Hide comment
@o-

o- Jun 15, 2018

I have the same issue, even without rotation. I have a layout, where the primary display is at an offset in the virtual screen, when adding a second monitor. Basically the primary monitor is to the left, but shifted down with --pos 0x520 and the external monitor is moved to the right with --pos 1920x0. Clicking only works in the upper half of the primary monitor, ie. on the originalSize-520 top pixels.

This is my full xrandr line (generated by arandr): xrandr --output HDMI-1 --off --output eDP-1 --primary --mode 1920x1080 --pos 0x520 --rotate normal --output DP-2 --mode 2560x1600 --pos 1920x0 --rotate normal

The app vm sees:

Screen 0: minimum 64 x 64, current 1920 x 1080, maximum 32767 x 32767
DUMMY0 connected primary 1920x1080+0+0 325mm x 182mm
   QB1920x1080   46.10*+
DUMMY1 disconnected
   QB2560x1600   59.99  

ie, the pos is missing and the second monitor appears disconnected.

o- commented Jun 15, 2018

I have the same issue, even without rotation. I have a layout, where the primary display is at an offset in the virtual screen, when adding a second monitor. Basically the primary monitor is to the left, but shifted down with --pos 0x520 and the external monitor is moved to the right with --pos 1920x0. Clicking only works in the upper half of the primary monitor, ie. on the originalSize-520 top pixels.

This is my full xrandr line (generated by arandr): xrandr --output HDMI-1 --off --output eDP-1 --primary --mode 1920x1080 --pos 0x520 --rotate normal --output DP-2 --mode 2560x1600 --pos 1920x0 --rotate normal

The app vm sees:

Screen 0: minimum 64 x 64, current 1920 x 1080, maximum 32767 x 32767
DUMMY0 connected primary 1920x1080+0+0 325mm x 182mm
   QB1920x1080   46.10*+
DUMMY1 disconnected
   QB2560x1600   59.99  

ie, the pos is missing and the second monitor appears disconnected.

@pgerber

This comment has been minimized.

Show comment
Hide comment
@pgerber

pgerber Jun 27, 2018

I also have this issue without rotation. However, it only affects AppVMs that were started before the monitor was plugged in.

Going through the logs, I suspect this error is related:

Jun 27 21:07:09 disp3386 qubes.SetMonitorLayout-dom0[1196]: X Error of failed request:  BadMatch (invalid parameter attributes)
Jun 27 21:07:09 disp3386 qubes.SetMonitorLayout-dom0[1196]:   Major opcode of failed request:  139 (RANDR)
Jun 27 21:07:09 disp3386 qubes.SetMonitorLayout-dom0[1196]:   Minor opcode of failed request:  7 (RRSetScreenSize)
Jun 27 21:07:09 disp3386 qubes.SetMonitorLayout-dom0[1196]:   Serial number of failed request:  196
Jun 27 21:07:09 disp3386 qubes.SetMonitorLayout-dom0[1196]:   Current serial number in output stream:  197
Jun 27 21:07:10 disp3386 qubes.SetMonitorLayout-dom0[1252]: X Error of failed request:  BadMatch (invalid parameter attributes)
Jun 27 21:07:10 disp3386 qubes.SetMonitorLayout-dom0[1252]:   Major opcode of failed request:  139 (RANDR)
Jun 27 21:07:10 disp3386 qubes.SetMonitorLayout-dom0[1252]:   Minor opcode of failed request:  7 (RRSetScreenSize)
Jun 27 21:07:10 disp3386 qubes.SetMonitorLayout-dom0[1252]:   Serial number of failed request:  196
Jun 27 21:07:10 disp3386 qubes.SetMonitorLayout-dom0[1252]:   Current serial number in output stream:  197

xrand on AppVM where screen was not plugged in during boot (mouse not working):

[user@disp3386 ~]$ xrandr
Screen 0: minimum 64 x 64, current 2560 x 1440, maximum 32767 x 32767
DUMMY0 connected primary 2560x1440+0+0 325mm x 182mm
   QB2560x1440   34.61*+
DUMMY1 connected 1920x1200+0+0 162mm x 101mm
   QB2560x1440   34.61 +
   QB1920x1200   59.88* 
DUMMY2 disconnected
…

xrand on AppVM where screen was plugged in during boot (mouse working):

[user@disp5697 ~]$ xrandr
Screen 0: minimum 64 x 64, current 4480 x 1440, maximum 32767 x 32767
DUMMY0 connected primary 2560x1440+0+0 325mm x 182mm
   QB4480x1440   34.63 +
   QB2560x1440   59.96* 
DUMMY1 connected 1920x1200+2560+0 162mm x 101mm
   QB4480x1440   34.63 +
   QB1920x1200   59.88* 
DUMMY2 disconnected
…

pgerber commented Jun 27, 2018

I also have this issue without rotation. However, it only affects AppVMs that were started before the monitor was plugged in.

Going through the logs, I suspect this error is related:

Jun 27 21:07:09 disp3386 qubes.SetMonitorLayout-dom0[1196]: X Error of failed request:  BadMatch (invalid parameter attributes)
Jun 27 21:07:09 disp3386 qubes.SetMonitorLayout-dom0[1196]:   Major opcode of failed request:  139 (RANDR)
Jun 27 21:07:09 disp3386 qubes.SetMonitorLayout-dom0[1196]:   Minor opcode of failed request:  7 (RRSetScreenSize)
Jun 27 21:07:09 disp3386 qubes.SetMonitorLayout-dom0[1196]:   Serial number of failed request:  196
Jun 27 21:07:09 disp3386 qubes.SetMonitorLayout-dom0[1196]:   Current serial number in output stream:  197
Jun 27 21:07:10 disp3386 qubes.SetMonitorLayout-dom0[1252]: X Error of failed request:  BadMatch (invalid parameter attributes)
Jun 27 21:07:10 disp3386 qubes.SetMonitorLayout-dom0[1252]:   Major opcode of failed request:  139 (RANDR)
Jun 27 21:07:10 disp3386 qubes.SetMonitorLayout-dom0[1252]:   Minor opcode of failed request:  7 (RRSetScreenSize)
Jun 27 21:07:10 disp3386 qubes.SetMonitorLayout-dom0[1252]:   Serial number of failed request:  196
Jun 27 21:07:10 disp3386 qubes.SetMonitorLayout-dom0[1252]:   Current serial number in output stream:  197

xrand on AppVM where screen was not plugged in during boot (mouse not working):

[user@disp3386 ~]$ xrandr
Screen 0: minimum 64 x 64, current 2560 x 1440, maximum 32767 x 32767
DUMMY0 connected primary 2560x1440+0+0 325mm x 182mm
   QB2560x1440   34.61*+
DUMMY1 connected 1920x1200+0+0 162mm x 101mm
   QB2560x1440   34.61 +
   QB1920x1200   59.88* 
DUMMY2 disconnected
…

xrand on AppVM where screen was plugged in during boot (mouse working):

[user@disp5697 ~]$ xrandr
Screen 0: minimum 64 x 64, current 4480 x 1440, maximum 32767 x 32767
DUMMY0 connected primary 2560x1440+0+0 325mm x 182mm
   QB4480x1440   34.63 +
   QB2560x1440   59.96* 
DUMMY1 connected 1920x1200+2560+0 162mm x 101mm
   QB4480x1440   34.63 +
   QB1920x1200   59.88* 
DUMMY2 disconnected
…
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment