CachyOS-Settings icon indicating copy to clipboard operation
CachyOS-Settings copied to clipboard

Zenity on GTK 4 with libadwaita: Unsupported gtk-modules and theme warnings

Open p2ndemic opened this issue 9 months ago • 2 comments

System Details

  • OS: CachyOS
  • Kernel: Linux 6.13.7-3-cachyos
  • DE: KDE Plasma (Wayland)
  • Zenity version: 4.1.90
  • GTK 4 version: 1:4.18.2-1.
  • libadwaita version: 1:1.7.0-2.1

Description

When running zenity on CachyOS with KDE Plasma, I encounter the following warnings:

❯ zenity

(zenity:2449): Gtk-WARNING **: 01:40:58.155: Unknown key gtk-modules in /home/admin/.config/gtk-4.0/settings.ini

(zenity:2449): Adwaita-WARNING **: 01:40:58.246: Using GtkSettings:gtk-application-prefer-dark-theme with libadwaita is unsupported. Please use AdwStyleManager:color-scheme instead.
~

micro ~/.config/gtk-4.0/settings.ini

[Settings]
gtk-application-prefer-dark-theme=true
gtk-cursor-theme-name=capitaine-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=breeze-dark
gtk-modules=colorreload-gtk-module:window-decorations-gtk-module
gtk-primary-button-warps-slider=true
gtk-sound-theme-name=ocean
gtk-xft-dpi=172032

This is the default configuration generated by CachyOS after installation. No manual changes were made to the file. Please check

screenshot1 screenshot2

p2ndemic avatar Mar 30 '25 21:03 p2ndemic

you can ignore that warning. generally that should be reported upstream to support such feature(if not yet emitted) https://invent.kde.org/plasma/breeze-gtk

vnepogodin avatar Mar 30 '25 21:03 vnepogodin

you can ignore that warning. generally that should be reported upstream to support such feature(if not yet emitted) https://invent.kde.org/plasma/breeze-gtk

Solution:

Remove or comment out the gtk-modules line in ~/.config/gtk-4.0/settings.ini, as this setting is not supported in GTK4:

[Settings]
# gtk-modules=colorreload-gtk-module:window-decorations-gtk-module # Remove or comment out
# Add instead
gtk-theme-name=Adwaita-dark

Toggle the gtk-application-prefer-dark-theme flag from true to false: gtk-application-prefer-dark-theme=false

Screen1:

Result: Screen2

vnepogodin, could you please take a look and make these default changes if necessary or do we have to wait for kde's solution?

Settings: https://github.com/CachyOS/cachyos-kde-settings/tree/develop/etc/skel/.config/gtk-4.0

p2ndemic avatar Mar 30 '25 21:03 p2ndemic

I think it should be fixed now with this commit https://github.com/CachyOS/cachyos-kde-settings/commit/7121d3a1f85fc279fc26ec9219f4f8596a16c0a0?

ventureoo avatar May 31 '25 17:05 ventureoo