Xpra: Ticket #2480: Command key is stuck on Mac OS and Wrong DPI

Xpra server 3.0.2 is installed on a Ubuntu 18.04 server. I'm using Mac OS 10.15 with Xpra 3.0.2 client to connect to the server.

Everything worked just fine with version 2.5.3, but after I updated to version 3.0.2, there are several bugs happened:

  1. The command key is stuck after being pressed.

This happens when option Control Command keys swap is checked. If I disable it, then the command/control key work normally. However, it's very inconvenient since everything on Mac using the command key.

  1. The DPI is wrong.

On my Mac, I set the display is "More Space". This is the log when I connect:

2019-11-15 15:08:21,315  client root window size is 1920x1200 with 1 display:
2019-11-15 15:08:21,315   phis-macbook-pro.local (11149x12689 mm - DPI: 4x2) workarea: 1920x1156
2019-11-15 15:08:21,316     monitor 2 (330x207 mm - DPI: 147x147)

I don't know if saying wrong DPI is true in this case because I have the same log when I run the version 2.5.3. The different is: everything on version 3.0.2 is so small. I try to change the dpi to 72 with the options --dpi=72 but it does not help.

  1. OpenGL: When using --opengl=on, if I make any windows full screen, then it will crash.

Right now I have to downgrade to version 2.5.3.



Mon, 18 Nov 2019 10:12:27 GMT - Antoine Martin: owner changed

The command key is stuck after being pressed.

Must be a change with GTK3.

The DPI is wrong. 2019-11-15 15:08:21,315 phis-macbook-pro.local (11149x12689 mm - DPI: 4x2) workarea: 1920x1156

I doubt that your macbook's display is 11 meters wide! So the values we get from the OS / GTK3 are bogus... Can you please run and post the output of:

Xpra.app/Contents/Helpers/GTK_info
Xpra.app/Contents/Helpers/NativeGUI_info
Xpra.app/Contents/Helpers/OpenGL_check

I will hack the correct values I get from my test system and see how we can deal with bogus values like yours. I guess that we can start by clamping the monitor size to reasonable values. (and make it configurable in case anyone runs xpra on a wall display with actual low DPI)

OpenGL: When using --opengl=on, if I make any windows full screen, then it will crash.

Can you please post the debug.log output of the command line if you run it as:

Xpra.app/Contents/Helpers/Xpra attach ssh://username@host/ -d all >& debug.log

Fri, 22 Nov 2019 01:42:28 GMT - Antoine Martin: component changed

The command key is stuck after being pressed.

Any specific key combination? Or is press then unpress enough? I still have to look into this issue. This is going to be "fun" to reproduce with a virtual machine and keyboard pass-through.

OpenGL: When using --opengl=on, if I make any windows full screen, then it will crash.

Could somehow be related to #2482. The latest beta builds fix that: https://xpra.org/beta/MacOS/ But having the OpenGL_check output would still be very useful (no matter what version you use to get it).

The DPI is wrong.

r24470 should fix that: we'll use the monitor DPI if we have to, which is valid in your case (monitor 2 (330x207 mm - DPI: 147x147)) and ignore the totally bogus values we get from GTK3.

There are beta 4.0 builds with these fixes here: https://xpra.org/beta/MacOS.


Fri, 22 Nov 2019 10:03:12 GMT - Antoine Martin:

Now for the keyboard stuff (got slightly distracted by #2491).

Support isn't perfect, for example I do see some temporary spurious key events. But those are mostly harmless and I certainly don't see any stuck keys, "Command" or even any other key. I even tried "Command-Tabbing" away to see if that would cause problems.

The test command xpra keyboard-test shows those key events.

@bya: please provide more information (ie: exact steps to reproduce, screenshot of xpra keyboard-test running within the session showing the problem, bug report data, etc..) or I will have to close this ticket as "needinfo".


Fri, 22 Nov 2019 18:45:41 GMT - bya:

@bya: please provide more information (ie: exact steps to reproduce, screenshot of xpra keyboard-test running within the session showing the problem, bug report data, etc..) or I will have to close this ticket as "needinfo".

Sorry for the late reply. There are multiple users using xpra on our server, that's why I haven't updated it again to report more information. I'll see if I can reproduce those errors on another machine.


Sat, 30 Nov 2019 01:53:44 GMT - Antoine Martin:

It seems that some DPI problems remain, more info provided in #2500


Sat, 30 Nov 2019 11:36:52 GMT - Antoine Martin:

r24470 was incomplete, r24535 fixes that.


Wed, 01 Apr 2020 16:03:17 GMT - Antoine Martin: status, milestone changed; resolution set


Sat, 23 Jan 2021 05:52:27 GMT - migration script:

this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/2480