xrdp icon indicating copy to clipboard operation
xrdp copied to clipboard

Mouse cursor clipped on HiDPI screen

Open t123yh opened this issue 2 years ago • 15 comments

Step to reproduce:

  1. Launch GNOME on xrdp and xorgxrdp.
  2. Set "Scale" to 200% under Settings->Displays.
  3. The mouse cursor is clipped. Only the top part is shown.

(Sorry for screenshot done with camera, but I'm unable to capture the cursor using screenshot utility)

截屏2021-12-21 上午10 43 20

I'm currently connected using MS macOS RDP client. I'll test later with MS mstsc on Windows.

OS: Ubuntu 20.04, xrdp version: 0.9.17

Update: just tried with MSTSC, got the same behavior.

t123yh avatar Dec 21 '21 02:12 t123yh

It seems that cursor size is limited to 32 in current code. Can it be larger or dynamically adjusted?

t123yh avatar Dec 22 '21 02:12 t123yh

At the moment I don't think so, although the spec allows for it. We'd need to support a feature called 'large pointers', but I can' see any evidence for it in the code.

This is related to #1333, which also needs this capability to be supported.

matt335672 avatar Dec 22 '21 09:12 matt335672

Hi Matt,

Thanks for your reply. That issue seems to be hanging around for a while. Is it likely that this feature get implemented in the future?

t123yh avatar Dec 22 '21 09:12 t123yh

It's not got a high priority I'm afraid. All our significant effort at the moment is going into GFX and reworking the authentication architecture.

matt335672 avatar Dec 22 '21 10:12 matt335672

I came here to report the same thing. My client monitor is 4K (200% DPI) and my mouse cursor size 2 in Windows' settings. The server is Manjaro Gnome.

If I use Windows' in-built RDP client and select full-screen, Gnome's resolution becomes 4K and 200% scale. The cursor gets clipped. image

If I use mRemoteNG and set full-screen, Gnome's resolution becomes 1080p and 100% scale (I think mRemoteNG doubles the server's screen on the client side). The cursor looks tiny.

image

This tiny or clipped cursor makes it difficult to use RDP. I did not have such problems when I used Windows' in-built RDP server. The cursor size was the same as my client Windows' cursor size, 2.

HubKing avatar May 09 '22 02:05 HubKing

I added #2259 for this. I have some patches around somewhere that fix this.

jsorg71 avatar May 11 '22 06:05 jsorg71

And after not being able to just use the cursor on the client side without a double cursor.. I change the server x11vnc parameter just to run into another problem.. cursor clipping. At least this ticket isn't closed.. but still disappointing that cursors are this broken in xrdp - even if you want to work around issue it's still difficult.

rbreaves avatar Jun 19 '22 05:06 rbreaves

Not a pretty looking cursor when done this way under hidpi for Ubuntu... but you can just divide your cursor size in half via gsettings as a quick work around.

So for my 24px size cursor I am now just setting it to 12.. works well enough for me, even thought it looks low res now. Obviously not a proper fix, but better than clipping or double mouse cursors till one of us has the time to really dig into this and fix it one way or another.

gsettings set org.gnome.desktop.interface cursor-size 12

rbreaves avatar Jun 19 '22 05:06 rbreaves

gsettings set org.gnome.desktop.interface cursor-size 12

Judging by the comment, I thought it would keep the size but only make blurry ("low-res") but now, it only made the cursor smaller. This is not any better than clipped normal-size cursor, because it is difficult to see anyway.

HubKing avatar Jun 19 '22 08:06 HubKing

Judging by the comment, I thought it would keep the size but only make blurry ("low-res")

I guess for me it’s the size I was expecting but perhaps you wanted larger to begin w/ so dividing by half does do it for you. Fractional scaling might be problematic too.

One option you have is to render the cursor locally & then figure out a VNC client that can shut off the cursor on the local PC so you only see the remote.

x11vnc w/ -nocursorshape keeps my remotes cursor but unless you have a good vnc client you might end up w/ double cursors.

Also to note - I am on a Mac w/ Jump Desktop & it cannot turn off my local cursor but what I described as a work around.. dividing the cursor size by half works for me, just low res.

On the Windows.. I end up using either RealVNC or ultravnc & passing in -no cursor to one of their exe’s.. plus using an AHK hack to remove the window border because going fullscreen normally prevents access to my taskbar.

Windows is just a bigger mess to Remote Desktop from than macOS period & Linux leaves me fiddling around.. I’m kinda done w/ it all. I’ll remote in either but I’m getting sick of having either local.

rbreaves avatar Jun 19 '22 14:06 rbreaves

gsettings set org.gnome.desktop.interface cursor-size 12

gsettings set org.gnome.desktop.interface cursor-size 20

is better.

riverscn avatar Aug 29 '22 01:08 riverscn

I'm having the same issue with Linux Mint Cinnamon. I've installed it on a Hyper-V guest VM, installed the xrdp package, and connected from my Windows 11 host operating system.

I'm on 4k screens @ 200% DPI scaling as well.

I tried changing the cursor to the Google Dot, but no matter which cursor, they are all cut off.

PXL_20230701_082111462

pcgeek86 avatar Jul 01 '23 08:07 pcgeek86

Thought I'd give Linux a try in a Hyper-V VM. Mouse cursor doesn't work because of this bug. Well, I guess this isn't the year of Linux on the desktop yet again. How can this not be a higher priority? It makes the OS impossible to use comfortably on HighDPI monitors.

Russ1642 avatar Oct 27 '23 23:10 Russ1642

I think this is fixed in devel, for the Xorg back-end at least. See #2315. I haven;t been working on it myself, so I can't say for sure,

matt335672 avatar Oct 28 '23 15:10 matt335672

I met the same question when KDE in Debian12 remote by Microsoft RDP for Mac, a temporary solution is to choose the smallest cursor size, but it's too small.

theaimer09 avatar Mar 04 '24 02:03 theaimer09

seems it was fixed on v0.10 release. Just need to wait it to roll out on different linux dists https://github.com/neutrinolabs/xrdp/pull/2670 https://github.com/neutrinolabs/xrdp/commit/24d115824d848d9a4867b7fcbf2ab8be89f94744

soda92 avatar May 12 '24 14:05 soda92

As @soda92 reported, it is fixed in v0.10.0 release.

metalefty avatar May 13 '24 02:05 metalefty