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

Mouse pointer is scaled as of display config is scaled #61

Open
noomz opened this issue Apr 23, 2021 · 14 comments
Open

Mouse pointer is scaled as of display config is scaled #61

noomz opened this issue Apr 23, 2021 · 14 comments
Labels
bug Something isn't working

Comments

@noomz
Copy link

noomz commented Apr 23, 2021

Environment

Windows build number:  10.0.21364.0
Your Distribution version:  Ubuntu 20.04.2 LTS on Windows 10 x86_64
Your WSLg version: 1.0.17.1

Steps to reproduce

  1. Set display Scale and layout option to more than 100% eg: 250%.
  2. Install and run gnome-terminal

WSL logs:

  • versions.txt
     WSLg ( x86_64 ): 1.0.17+3.Branch.master.Sha.a526dfd5ad03d126bb2d8c528f6c3563e86a40da
     Mariner: VERSION="1.0.20210224"
     FreeRDP: e4a2fc2053bd8c5f99455fcd08ffee7e5591567a
     weston: fd961f5cd116c9358d82ce94d139c1578e21bd00
     pulseaudio: 2f0f0b8c3872780f15e275fc12899f4564f01bd5
     mesa:
    

Expected behavior

The pointer should have a normal size compared to running apps. Text selection should be selected only under that cursor.

Actual behavior

It's scaled to a bigger size and does wrong text selection.

Demo Video:

wslg-pointer-bug-s.mp4

Display Config:

image

@noomz noomz added the bug Something isn't working label Apr 23, 2021
@hideyukn88
Copy link
Member

@noomz , please refer #23 and enable fractional scaling support and check if it solves.

@noomz
Copy link
Author

noomz commented Apr 24, 2021

@hideyukn88 Nope. It doesn't work. It's the UI interface that changes, the mouse pointer size is still big and fail on selection.

spronovo pushed a commit that referenced this issue Apr 26, 2021
Co-authored-by: Ben Hillis <benhill@ntdev.microsoft.com>
@ati46
Copy link

ati46 commented Apr 30, 2021

@hideyukn88
It can't be solved, and the mouse will be enlarged whether it is on 200% desktop or 100% desktop.
I use archlinux. The system I used before wslg did not increase the size of the application mouse after upgrading to wslg, but my newly installed system showed that the mouse became larger.

When the mouse is placed on the border, it is not enlarged, only when it is placed in the menu or text area.

@hideyukn88
Copy link
Member

@ati46 , I am not able to reproduce that enlarged cursor in your video with Ubuntu 20.04 LTS with gnome-terminal. For reference, would you please check if your gnome-terminal is running in X11 backend or Wayland mode ? (For me I can't repro in both mode though) Normally by default, it runs on wayland mode (as WSLg runs on wayland compositor), but can switch to X11 backend by "export GDK_BACKEND=x11".

Also, the regarding to selection, the cursor's hotspot is upper left corner of cursor bounding box, not center of cursor image, please check if selection is made at hotspot? Thanks!

@noomz
Copy link
Author

noomz commented May 2, 2021

After restart yesterday, the mouse pointer is not large, and, gnome-terminal is not scaled too (previously scaled). No further configuration on WSLg. And the selection hotspot is at the center of the characters, not the left corner.

wslg-pointer-bug-s2.mp4

@noomz
Copy link
Author

noomz commented Jun 9, 2021

After last windows 10 next updated today. The cursor is still scaled.

@rizhenkov
Copy link

Windows 11 cursor it too big. But this solution can solve the issue as temporary solution.
sudo apt-get update
sudo apt-get install dconf-tools
dconf-editor
navigate to org.gnome.desktop.interface
and change cursor-size from 24 to 12.

image

@parrenin
Copy link

I have the same issue here on Windows11/WSLg with a 4k screen / 200% scaling.
The pointer is too big.
I changed the pointer size using gsettings, with works for the standard cursor, but not for custom cursors which are created by some application (e.g., gnumeric).

@MumenAlmadaineh
Copy link

Windows 11 cursor it too big. But this solution can solve the issue as temporary solution. sudo apt-get update sudo apt-get install dconf-tools dconf-editor navigate to org.gnome.desktop.interface and change cursor-size from 24 to 12.

image

I face this error E: Unable to locate package dconf-tools when I try sudo apt-get install dconf-tools can you please help me with this

@Reflyer823
Copy link

Windows 11 cursor it too big. But this solution can solve the issue as temporary solution. sudo apt-get update sudo apt-get install dconf-tools dconf-editor navigate to org.gnome.desktop.interface and change cursor-size from 24 to 12.
image

I face this error E: Unable to locate package dconf-tools when I try sudo apt-get install dconf-tools can you please help me with this

Just install dconf-editor is enough.

@bluelu
Copy link

bluelu commented Sep 13, 2022

I have the same issue (in intellijidea). The cursor is correct on the menubar, but huge when over the text area. It's probably related to some old setting/configuration:

image

@Memoraike
Copy link

Try this >
Size - integer value
echo "Xcursor.size: Size" > ~/.Xresources
xrdb -load ~/.Xresources

@georgio
Copy link

georgio commented Sep 27, 2023

If you're using wayland, this might work for you:

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

This sets the size to 12 which looks to me about the same size as that of the native cursor. You can change the size to whatever you want.

To view the current value:
gsettings get org.gnome.desktop.interface cursor-size

@psarraf
Copy link

psarraf commented Dec 3, 2023

The gsettings workaround is unacceptable if you are using waypipe to access a remote machine. Microsoft needs to fix this bug that has been reported more than two years ago. They haven't even acknowledged it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests