xpra icon
Bug tracker and wiki

Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#746 closed defect (fixed)

Default X cursor shows in some applications

Reported by: nathan-renniewaldock Owned by: Nick Centanni
Priority: major Milestone:
Component: client Version: 0.14.x
Keywords: Cc:

Description

Some apps are showing the default X cursor instead of the usual arrow, it appears to be mainly menus and java apps. Menus worked more reliably in 0.11.1, but java apps were the same.

What I've noticed:

0.11.1:

  • Cursor is correct in menus, but not on the button for them
  • Default X cursor is the same size as other cursors
  • Seems to use local cursors in client (so I get system cursors on Windows)


0.14.1:

  • Cursor is wrong on buttons and in menus but after moving around them repeatedly, it does eventually change
  • Default X cursor is around double the size of other cursors
  • Seems to use server cursors, so I get a fairly ugly cursor on links

Attachments (8)

lxterminal - xpra 0.11.1 (1).png (52.2 KB) - added by nathan-renniewaldock 6 years ago.
lxterminal - xpra 0.11.1 (2).png (63.3 KB) - added by nathan-renniewaldock 6 years ago.
lxterminal - xpra 0.14.11 (1).png (60.1 KB) - added by nathan-renniewaldock 6 years ago.
lxterminal - xpra 0.14.11 (2).gif (3.3 MB) - added by nathan-renniewaldock 6 years ago.
firefox - xpra 0.11.1.png (152.1 KB) - added by nathan-renniewaldock 6 years ago.
firefox - xpra 0.14.11.png (152.3 KB) - added by nathan-renniewaldock 6 years ago.
xpra client (firefox).log (10.0 KB) - added by nathan-renniewaldock 6 years ago.
xpra server (firefox).log (24.1 KB) - added by nathan-renniewaldock 6 years ago.

Change History (25)

Changed 6 years ago by nathan-renniewaldock

Changed 6 years ago by nathan-renniewaldock

Changed 6 years ago by nathan-renniewaldock

Changed 6 years ago by nathan-renniewaldock

Changed 6 years ago by nathan-renniewaldock

Attachment: firefox - xpra 0.11.1.png added

Changed 6 years ago by nathan-renniewaldock

Attachment: firefox - xpra 0.14.11.png added

comment:1 Changed 6 years ago by Antoine Martin

Owner: changed from Antoine Martin to nathan-renniewaldock

Do you have a patched Xdummy dummy driver installed properly? (that's usually the cause of the problems with size issues)

(if not, make sure you also install a fixed libfakeXinerama - fixes others related issues)

0.14.1 is well out of date, please try the latest - there were cursor fixes recently.

0.14 does more cursor batching than previously, so we will delay sending the cursor pixels a little bit to prevent swamping the connection with it.

It could also be because we try to use the client-side cursor from the current GTK theme in use, if we find any. Changing the theme, or even deleting the theme icons may prevent client-side cursors from being used.

If none of this fixes things for you, please run both the client and server with -d cursor so we can get debug output. You can also capture xpra info | grep cursor when things are misbehaving.

Please make sure to specify client and server OS, etc..

Last edited 6 years ago by Antoine Martin (previous) (diff)

comment:2 Changed 6 years ago by nathan-renniewaldock

Hadn't noticed there was a new version, only downloaded it about a week ago.

Updating client to 0.14.12 fixed the cursor size, but I'm still getting the default X cursor in some places. I don't have a patched Xdummy driver, I'll update X and try again at the weekend.

Client: Windows 7
Server: Ubuntu 12.04

comment:3 Changed 6 years ago by Antoine Martin

I don't have a patched Xdummy driver
(...)
Server: Ubuntu 12.04


Using the patched xdummy will probably not fix the default X11 cursor issue.
And you would have to build from source since we do not provide patched xdummy packages for Debian or Ubuntu.

Probably best to go with -d cursor instead.

comment:4 Changed 6 years ago by nathan-renniewaldock

Yeah, I don't mind building from source. But Ubuntu have a backport of xorg 1.15, installed that and checked quickly.. cursor on menus was still wrong and in lxterminal the text cursor was double the size. I'll take a look at the debug output at the weekend. Would Xinerama possibly help or not?

comment:5 Changed 6 years ago by Antoine Martin

Ubuntu have a backport of xorg 1.15, installed that and checked quickly


I very much doubt that any backport will have the patches that we carry for dummy. As those patches aren't upstream at all.

Would Xinerama possibly help or not?


That's highly unlikely.

comment:6 Changed 6 years ago by nathan-renniewaldock

That's not what the wiki page says, which links to the patches on upstream's git.

Most recent distributions now ship compatible packages though some may have issues with non world-readable binaries (see below), for those that ship outdated versions there are two changes to core Xorg code which are needed:
The ​xserver patch: which is part of the 1.12 xserver and later.
This ​xf86-video-dummy patch: which is part of version 0.3.5. (if your clients' screens are always smaller than 2048x2048, you may not need it)

comment:7 Changed 6 years ago by Antoine Martin

This page talks about the packages required for using Xdummy.

For DPI issues, you need more than just that.

comment:8 Changed 6 years ago by Antoine Martin

If you have time for some no-so-light reading, the DPI issues and dummy patches are discussed here: #163, #56

The patches that we are applying to our patched dummy rpms are here: browser/xpra/trunk/rpmbuild (constant dpi patch, you can skip pointer limits)

comment:9 Changed 6 years ago by nathan-renniewaldock

Alright, using Xdummy now with the DPI patch. Still getting weird sized cursors. Looking at the logs, it seems to be deciding the cursors should be displayed 32x32 but if I measure a Windows cursor from a screenshot, I get 16x16.

Changed 6 years ago by nathan-renniewaldock

Attachment: xpra client (firefox).log added

Changed 6 years ago by nathan-renniewaldock

Attachment: xpra server (firefox).log added

comment:10 Changed 6 years ago by Antoine Martin

TIL:

  • server side:
    cursor_event: <X11:CursorNotify {'delivered_to': '0x16d', 'send_event': 0, 'cursor_serial': 4L, \
        'window': '0x16d', 'cursor_name': 'left_ptr', 'serial': 1461L, 'type': 88, 'display': ':9999'}>
    get_cursor_data() cursor=[687, 519, 48, 48, 14, 8, 4L, '9216 bytes', 'left_ptr']
    do_send_cursor(..) pixels=LevelCompressed(cursor: 1997 bytes as lz4/21)
    do_send_cursor(..) 48x48 cursor 4 with delay=12
    
  • client side:
    cursor name 'left_ptr' not found
    server cursor sizes: default=85, max=(64, 64)
    new cursor at 14,8 with serial=4, dimensions: 48x48, len(pixels)=9216, default cursor size is 32, maximum=(32, 32)
    scaling cursor from 48x48 to fixed OS size 32x32
    downscaling cursor by 1.50
    

Translates to: your client build doesn't have the cursors in its theme, and so it cannot load them using their name (ie: left_ptr, xterm,..). So we fallback to using the given cursor pixel data.
The 32x32 size is the most common one I think, used in XP and others.

but if I measure a Windows cursor from a screenshot, I get 16x16


Interesting. Is your screen resolution detected correctly? (1440x900)
Do you have any font settings enabled? (large or small - see ticket:163#comment:45 for Windows 8, Windows 7 may well be different)

I think it's likely that the value we have is correct (32) but that Windows then scales it before using it. (unless the cursor looks crooked or cropped, that's the most likely explanation)

@nathan-renniewaldock:

  • in comment:2 you said: Updating client to 0.14.12 fixed the cursor size, but I'm still getting the default X cursor in some places.
  • in comment:9 you said: Alright, using Xdummy now with the DPI patch. Still getting weird sized cursors.

Which is it? Weird sized cursors or default X cursor?
Looking at the server log, it looks like we are sending what we get from the X11 server (a mix of left_ptr and xterm, and one hand2). Looks right to me.

Last edited 6 years ago by Antoine Martin (previous) (diff)

comment:11 Changed 6 years ago by cgf5177

I'm seeing large cursors after updating to 0.14.12 also. Both the "I" and the arrow are much bigger
than normal.

I'm using the default settings on the latest Fedora release except for:

# Forward sound output to clients:
speaker = no
# Publish sessions:
mdns = no
pulseaudio = no

If I start a new X client after xpra client and xpra host are connected then the cursors appear to be
normal. Clients started before any xpra client is connected seem to always exhibit the problem.

The two clients that I start prior to connection are "pidgin" and "xterm".

Last edited 6 years ago by Antoine Martin (previous) (diff)

comment:12 Changed 6 years ago by Nick Centanni

I have been able to reproduce this problem on 0.14.13 r8175, on Fedora 20. However, I only see the problem in the xterm window (large bar cursor). I see all normal-sized cursors when running browsers from the xterm session.

I have the following Xdummy driver installed:

xorg-x11-drv-dummy-0.3.6-11.fc20.x86_64

Last edited 6 years ago by Nick Centanni (previous) (diff)

comment:13 Changed 6 years ago by Antoine Martin

Owner: changed from nathan-renniewaldock to Antoine Martin
Status: newassigned

I am seeing this with 0.14.x svn on Fedora 20, but not with trunk.

Here's the cursor debug log:

cursor name 'xterm' not found
server cursor sizes: default=24, max=(64, 64)
new cursor at 22,22 with serial=2, dimensions: 48x48, len(pixels)=9216, default cursor size is 24, maximum=(128, 128)
downscaling cursor by 2.00

comment:14 Changed 6 years ago by Antoine Martin

Owner: changed from Antoine Martin to Nick Centanni
Status: assignednew

Should be fixed in r8178. Please close if this works for you.

comment:15 Changed 6 years ago by Nick Centanni

Resolution: fixed
Status: newclosed

It works for me, in 0.14.13 r8178.

comment:16 Changed 6 years ago by cgf5177

Sorry for the late response: It works for me too.

comment:17 Changed 6 years ago by nathan-renniewaldock

Hadn't noticed the emails, oop. Just updated to 0.14.14, fixed for me too.

Note: See TracTickets for help on using tickets.