Skip to content
Peter J. Mello edited this page Mar 12, 2020 · 1 revision

How does the script work?

The script detects your current icon theme, and the right icon size for the indicator icons by detecting the current Desktop environment. The script reads the database file gets the correct theme icons and fixes your hardcoded icons.

The only themes that cover almost every app that we support are Papirus and Numix. For best results you should select one of them through your desktop environment's settings.

Why installing a conversion tool (python3-cairosvg or inkscape)

We use that to convert SVG icons to PNG in case your theme has SVG icons. You can use the script without installing any one of them but only SVG icons will be fixed.

Why using sudo

Almost all the application icons are stored in /usr or /opt that's why we need root permissions to modify those files.

Why using sudo -E instead of sudo

We use sudo -E to preserve environment variables, to detect your Desktop environment. The script shouldn't be run using 'sudo' either sudo -E as it's already done on the code. Just run hardcode-tray

Default theme is not correctly detected?

It's a known issue with XFCE and KDE. The default icon theme is stored by default on org.gnome.desktop.interface icon-theme. Some KDE/XFCE applications used to customize your desktop environment does not modify this value. You can either change it using org.gnome.desktop.interface icon-theme "icon-theme" or use --theme icon-theme in order to force Hardcode-Tray to use the other icon theme, where "icon-theme" is the current icon theme you're using.

How to support an application in your theme

Open the application file in database/applicationname.json > icons. If there's a theme key, this icon name should be used. If not you should provide all the icons in icons key. Please follow freedesktop.org standards