December 4, 2021

Giving VirtualBox a dark mode

We all love our dark mode, don't we, folks? System-wide themes usually take care of that for us. But what about software written in a different GUI system? QT apps will often not respect your system-wide settings. But we will make them do so anyway.

Giving VirtualBox a dark mode

The solution is actually fairly easy. Qt5 has a tool called qt5ct that allows us to change some of its settings.

We'll install it with sudo apt-get install qt5ct -y. For the next step, we need to set a permanent environment variable. This will ensure that all Qt apps will use the custom qt5ct settings. Open up your ~/.profile file and add export QT_QPA_PLATFORMTHEME=qt5ct. Next up, start qt5ct with qt5ct in the terminal.

In the first tab, simply switch "Palette" to Custom. You can now change the color scheme to your liking. I can recommend "darker". Once you're done, apply the settings. Start the Qt app of your choice, and enjoy not having your retinas burned out of your eyes.