How do I make the vala preffer app a dark GTK theme?

I have vala app and I would like it to use dark gtk theme instead of default highlighting.

Gtkparasite "Use dark option" allows me to do this, but how can I do it programmatically?


source to share

1 answer

Ok I found a way. Before creating any widget, the following must be done:

Gtk.Settings.get_default().set("gtk-application-prefer-dark-theme", true);




All Articles