Running Qt5 applications outside KDE
I run i3
as window manager but like to use some applications from the KDE suite, such as KOrganizer, for their maturity and customizability.
Without further configuration, however, the font sizes in such applications are odd and no icons appear.
It turns out this is due to a new feature in Qt5: the application theme is not set globally but inferred from the environment.
An effective workaround is to use qt5ct
.
One simply installs qt5ct
and adds
export KDE_SESSION_VERSION=5
export KDE_FULL_SESSION=true
export QT_QPA_PLATFORMTHEME=qt5ct
to the xsession
initialization script or to .profile
.
After running these export commands, run qt5ct
to select a Qt5 theme, and your Qt5 applications will finally behave.
Note that qt5ct
is not yet available in Debian Stretch:
I obtained it from https://bitbucket.org/yarosla/qt5ct-builder/overview.