I have installed qt5ct to apply gtk2 theme on Qt apps (by default they follow the Fusion theme). However, Qt apps (I have tried GNU Octave and Brightness Controller) are taking too much time to start up when the gtk2 theme is enabled.

For example, Brightness Controller is taking ~25 seconds to load in gtk2 theme in qt5ct, while it takes 1-2 seconds to load under Fusion or any other theme (I have measured this by looking at a watch after clicking the icon).

The same goes for GNU Octave.

How to fix this? Please let me know whether I need to post any logs.

qt5ct itself is also very slow to load.

I have used qt5ct before in previous versions of Xubuntu, and there it was much faster.

  • I think Qt apps work best in a Qt desktop environment. The method you describe uses emulation, and it will always make things slower. Have you tried with Lubuntu or Kubuntu? – sudodus Apr 30 '20 at 12:39
  • Well, things like Octave have no GTK equivalent, and some developers use PySide to develop GUIs, which would make it qt. Also, I have used these in Xubuntu 19.10, where this issue was absent. It might have been slower in Xubuntu 19.10, but it was not noticeably slower (eg. here it takes 20+ seconds vs 2 seconds) – Archisman Panigrahi Apr 30 '20 at 12:48
  • Incidentally, when called from menu, Qt apps are following gtk2 theme despite whatever theme is selected in qt5ct, and these are slow. However, when called from terminal, these are following the theme selected in qt5ct and they are fast (unless gtk2 is selected in qt5ct). I have asked this here. askubuntu.com/questions/1233431/… – Archisman Panigrahi Apr 30 '20 at 12:51
  • Then you should call this from terminal (maybe via a desktop file, if you like) :-) – sudodus Apr 30 '20 at 12:55
  • I am a co-developer of Brightness Controller. And since this is also present in Octave, this seems to be a bug with either qt or qt5ct or the binding between XFCE's window manager and Qt. Any suggestion where I should report the bug? – Archisman Panigrahi Apr 30 '20 at 12:57

The startup speed of qt applications in clean installs of GNOME-based, 19.10+ versions of Ubuntu, its official flavors and derivatives is much longer if one tries to style them to appear consistent with native GNOME applications.


For whatever reason, users who upgrade from 19.04 don't see this problem.

Anyway, one satisfactory workaround is based on using Kvantum. See, for example, Use Custom Themes For Qt Applications (And Fix Qt5 Theme On GNOME) On Linux With Kvantum.

As described in the preceding link, since Kvantum isn't installed by default, it can be installed on 20.04 using

sudo apt install qt5-style-kvantum qt5-style-kvantum-themes

A ppa is available:

sudo add-apt-repository ppa:papirus/papirus
sudo apt update
sudo apt install qt5-style-kvantum qt5-style-kvantum-themes

After that, run

echo "export QT_STYLE_OVERRIDE=kvantum" >> ~/.profile

Log out and log back in. The link also has instructions for using Kvantum system-wide (with export QT_STYLE_OVERRIDE=kvantum in /etc/environment) and for uninstalling it.

  • Using kvantum caused problems on Ubuntu 20.10 with root apps (added it to /etc/environment), this one is a more simple approach that works with user and root apps: askubuntu.com/a/748186/79691 – DMT Nov 24 '20 at 15:18
  • This worked for me in Linux Mint 20 Cinnamon. – Kendor Nov 25 '20 at 4:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.