site  contact  subhomenews

Set Chromium colour theme to match system

June 17, 2026 — BarryK

The current system theme is kind of orange, but Chromium starts up as a blue theme inside the window. In a new tab, at bottom-right of the window, there is a "Customize Chromium" button, where you can choose a colour theme.

However, I would like to set it automatically appropriately as the default. In /root/.packages/default-theme, there is a new variable:

#choose chromium theme (default is blue). allowed values: "orange", "yellow"
DEFAULT_THEME_CHROMIUM='orange'

In woofQ2, script woofq2/rootfs/4post-process-rootfs reads this and appends the appropriate text:

#chromium theme (default is blue)...
case "$DEFAULT_THEME_CHROMIUM" in
orange) echo -n ',"theme":{"color_variant2":1,"user_color2":-32768}' >> rootfs/root/.config/chromium/Default/Preferences ;;
yellow) echo -n ',"theme":{"color_variant2":1,"user_color2":-336013}' >> rootfs/root/.config/chromium/Default/Preferences ;;
esac

However, as Chromium defaults to run as user "chromium", the script /usr/bin/chromium will copy these default settings into /home/chromium:

  if [ ! -d /home/chromium/.config/chromium/Default ];then
mkdir -p /home/chromium/.config/chromium
cp -a /root/.config/chromium/Default /home/chromium/.config/chromium/
cp -a -f "/root/.config/chromium/Local State" /home/chromium/.config/chromium/
chown -R ${UGID}:${UGID} /home/chromium

However, this will only work in a new installation, when Chromium has not yet been run. If you are updating an existing installation, you will have to manually choose the colour theme, as described in the first paragraph above.

I was thinking, if a later version of Easy reverted to a blue theme, perhaps a version update could delete that /home/chromium/.config/chromium/Preferences file, but that would wipe out other preferences.    

Tags: easy