You are not logged in.
As of recently, whenever I use a GTK4 app on KDE Wayland, the mouse cursor is huge whenever hovering the app window. Regardless if whether I am set to 125%, 150%, or 200% scaling in the KDE Display settings, the following error is printed out by the app:
(helvum:31475): Gdk-WARNING **: 13:09:27.565: ../gtk/gdk/wayland/gdkcursor-wayland.c:210 cursor image size (64) not an integer multiple of theme size (24)
It's really jarring and ugly to have a huge cursor jump into existence whenever I want to use a GTK 4 app. Has anyone else been having this issue, and is this a known issue as well? I appreciate all the help, thanks.
Edit:
Here is my ~/.config/gtk-4.0/settings.ini
[Settings]
gtk-application-prefer-dark-theme=true
gtk-cursor-theme-name=breeze_cursors
gtk-cursor-theme-size=24
gtk-decoration-layout=icon:minimize,maximize,close
gtk-enable-animations=true
gtk-font-name=Noto Sans, 10
gtk-icon-theme-name=Papirus-Dark
gtk-primary-button-warps-slider=true
gtk-sound-theme-name=ocean
gtk-xft-dpi=122880
Last edited by HurricanePootis (2024-09-21 18:14:23)
Offline
Same problem for me, celluloid and pavucontrol on Sway have a huge cursor
$ swaymsg -t get_outputs | grep -i scale
"scale": 1.5,
"scale_filter": "linear",
$ echo $XCURSOR_SIZE
28
$ gsettings get org.gnome.desktop.interface cursor-size
28
$ journalctl --user | grep celluloid | tail -n1
set 22 01:35:12 arch celluloid[3258]: ../gtk/gdk/wayland/gdkcursor-wayland.c:210 cursor image size (48) not an integer multiple of theme size (28)
Last edited by acubens (2024-09-21 23:41:17)
Offline
Yes, this started happening to me a few days ago after an update to gtk3 and gtk4, along with some other packages that I think were related to those. I tried changing the settings.ini cursor size for gtk3and4 but that didn't do anything. I tried downloading xdg-desktop-portal-gtk but that also didn't work. Then I tried resetting the gtk application theme in KDE system settings without any change.
Offline
Also having issues with this. Anyone know where to start looking?
Offline
Maybe we have to make an issue on GTK's gitlab?
Offline
I found a pull request here
Offline
It's a GTK4 bug. There are 3 workarounds:
1. Apply the patch in https://gitlab.gnome.org/GNOME/gtk/-/me … uests/7722 (Upper right corner, Code - Download Patch) and build your own GTK4.
2. Use other cursor themes than Breeze. E.g. Adwaita.
3. Build your own Breeze cursor theme:
3.1 Install `inkscape` and `xorg-xcursorgen`
3.1 `git clone https://github.com/kde/breeze`
3.2 Edit `breeze/cursors/src/build.sh`, change `NOMINAL_SIZE=24` to `NOMINAL_SIZE=32`.
3.3. `cd breeze/cursors/Breeze; ../src/build.sh; cp -r Breeze ~/.local/share/icons/breeze_cursors`
3.4. In SystemSettings - Cursor Theme, choose a new cursor size.
EDIT: GTK merged a different fix in https://gitlab.gnome.org/GNOME/gtk/-/me … uests/7749 and https://gitlab.gnome.org/GNOME/gtk/-/me … uests/7760 . But it won't work with Mutter at the moment. You can build that commit if you only use GTK apps in KDE. My original patch in point 1 should work with both GNOME and KDE.
Last edited by genericity (2024-09-29 02:15:24)
Offline
2. Use other cursor themes than Breeze. E.g. Adwaita.
I have this problem with the Capitaine-Cursors and Nordic-Cursors themes.
Now I'm temporarily using Breezex-lights theme and works properly.
Offline
I have this problem with the Capitaine-Cursors and Nordic-Cursors themes.
Now I'm temporarily using Breezex-lights theme and works properly. https://www.forumforyou.it/faccine/smile8/asd2.gif
It happens to quite a lot of themes that use the same build script as Breeze. The "NOMINAL_SIZE=32 and rebuild" trick in point 3 works for them too.
Offline
EDIT: GTK merged a different fix in https://gitlab.gnome.org/GNOME/gtk/-/me … uests/7749 and https://gitlab.gnome.org/GNOME/gtk/-/me … uests/7760 . But it won't work with Mutter at the moment. You can build that commit if you only use GTK apps in KDE. My original patch in point 1 should work with both GNOME and KDE.
Does this mean one of these days Im going to get a GTK4 package update and it will fix itself?
Offline
genericity wrote:EDIT: GTK merged a different fix in https://gitlab.gnome.org/GNOME/gtk/-/me … uests/7749 and https://gitlab.gnome.org/GNOME/gtk/-/me … uests/7760 . But it won't work with Mutter at the moment. You can build that commit if you only use GTK apps in KDE. My original patch in point 1 should work with both GNOME and KDE.
Does this mean one of these days Im going to get a GTK4 package update and it will fix itself?
Yes. It will be fixed in GTK 4.18, due Mar 2025.
Offline
Found a much easier fix on manjaro forums. Enter this command in terminal:
dconf write /org/gnome/desktop/interface/cursor-size 32
Offline
It's a GTK4 bug. There are 3 workarounds:
1. Apply the patch in https://gitlab.gnome.org/GNOME/gtk/-/me … uests/7722 (Upper right corner, Code - Download Patch) and build your own GTK4.
2. Use other cursor themes than Breeze. E.g. Adwaita.
3. Build your own Breeze cursor theme:
3.1 Install `inkscape` and `xorg-xcursorgen`
3.1 `git clone https://github.com/kde/breeze`
3.2 Edit `breeze/cursors/src/build.sh`, change `NOMINAL_SIZE=24` to `NOMINAL_SIZE=32`.
3.3. `cd breeze/cursors/Breeze; ../src/build.sh; cp -r Breeze ~/.local/share/icons/breeze_cursors`
3.4. In SystemSettings - Cursor Theme, choose a new cursor size.EDIT: GTK merged a different fix in https://gitlab.gnome.org/GNOME/gtk/-/me … uests/7749 and https://gitlab.gnome.org/GNOME/gtk/-/me … uests/7760 . But it won't work with Mutter at the moment. You can build that commit if you only use GTK apps in KDE. My original patch in point 1 should work with both GNOME and KDE.
After building the Breeze cursor theme it works fine until I restart. Then the cursors become invisible.
Offline