Is there a way to set the QT icon theme, and other theme elements, from the command line?
5
votes
1
answer
2352
views
I'm trying to automate the process of theming QT5 programs, in the absence of a DE like KDE, by writing a script that does it. I know that GTK has a bunch of config files that can specify all the aspects of a theme, but what's the equivalent for QT5?
So far, I've found out that I can set
QT_THEME_OVERRIDE
to set the theme, and XCURSOR_THEME
to set the cursor theme (QT5 appears to respect this). But what about the icon theme and everything else?
I've also seen [this Arch Wiki section](https://wiki.archlinux.org/index.php/qt#Configuration_of_Qt5_apps_under_environments_other_than_KDE_Plasma) about a similar issue, and a few other questions that suggest using the graphical configurator qt5ct
, but I'm really trying to write something that makes this change, rather than have a configurator do it, so that I don't have to repeat this process if I replicate my system install somewhere else.
(This is so I can write a .nix expression for home-manager that can handle qt5 theming declaratively, but that's beside the point.)
Asked by Jonathan
(1330 rep)
Aug 21, 2018, 06:40 PM
Last activity: Jun 7, 2025, 04:05 AM
Last activity: Jun 7, 2025, 04:05 AM