Cursor invisible in GTK apps

I use the Vanilla-DMZ cursor theme, as described in the wiki (Cursor Themes - NixOS Wiki). This seems to work fine for most applications, although I see different cursor EXWM/emacs as opposed to other applications (e.g. qutebrowser, urxvt).

However, for GTK applications (e.g. inkscape, nm-connection-editor), there is a transparent large X as cursor, indicating that GTK applications don’t make use of the Vanilla-DMZ cursor theme…
I’ve edited /home/moritz/.config/gtk-3.0/settings.ini to contain

gtk-cursor-theme-name=Vanilla-DMZ

instead of breeze_cursors (although ‘locate breeze_cursors’ shows some occurrences in my /nix/store), but still this does not fix the problem. I have

Xcursor.theme: Vanilla-DMZ

set in .Xresources, otherwise no cursor-related settings.

Thanks in advance and please let me know if further information might be helpful

1 Like

What desktop environment do you use, in some environment GTK uses the config file while in others it relies on XSettings or something else.

What does gsettings get org.gnome.desktop.interface cursor-theme print? You might need to run it with something like the following:

nix-shell -I "nixpkgs=channel:nixos-unstable" -p glib gsettings-desktop-schemas --run 'XDG_DATA_DIRS=$GSETTINGS_SCHEMAS_PATH gsettings get org.gnome.desktop.interface cursor-theme'

Thank you for your response! I use EXWM. I get Adwaita with your command.

[I] moritz@mopad ~ [1]> gsettings get  org.gnome.desktop.interface cursor-theme
No schemas installed
[I] moritz@mopad ~ [1]> XDG_DATA_DIRS=$GSETTINGS_SCHEMAS_PATH gsettings get  org.gnome.desktop.interface cursor-theme
No schemas installed
nix-shell -I "nixpkgs=channel:nixos-unstable" -p glib gsettings-desktop-schemas --run 'XDG_DATA_DIRS=$GSETTINGS_SCHEMAS_PATH gsettings get org.gnome.desktop.interface cursor-theme'
'Adwaita'

Then try the set subcommand to set it to whatever you want.

I am able to set it to “Vanilla-DMZ”, but the cursor still remains a full-white X (I assume it means that the cursor cannot be found). I would be fine with Adwaita, but it neither finds that one.

Solution: Missing some cursor icons - #4 by garret

xsetroot -cursor_name left_ptr

I am using the same setting, but I find the left_ptr in GTK applications looks different (worse) than it does in QT applications. Do you find the same thing? Am I doing something wrong?

I personally don’t care about the style so much at this moment. If you find a solution, please share though! :slight_smile:

I decided to look into this a bit. I found a list of available X Font Cursors:
https://tronche.com/gui/x/xlib/appendix/b/

On my system, left_ptr doesn’t look great. Not sure how these cursors are rendered, and how resolution/scaling, etc. affects them. I prefer the way top_left_arrow looks.

1 Like