If you look at the /usr/share/themes/*/gtk-3.x/gtk.css
file for any theme other than Adwaita (which is built in to Gtk, so it has no CSS file), you can see the color names that the themes use, though I have no idea whether they’re documented anywhere.
And, of course, looking at /usr/share/themes/Breeze/gtk-3.20/gtk.css
I see that while it defines names like @borders
for theme colors, it also styles its .entry
widgets with a custom color that doesn’t use any of the defined theming:
/* GTK NAMED COLORS
----------------
use responsibly! */
/*
widget text/foreground color */
@define-color theme_fg_color #232627;
/*
text color for entries, views and content in general */
@define-color theme_text_color #232627;
/*
widget base background color */
@define-color theme_bg_color #eff0f1;
/*
text widgets and the like base background color */
@define-color theme_base_color #fcfcfc;
/*
widgets main borders color */
@define-color borders #bcbebf;
/*
widgets main borders color on backdrop windows */
@define-color unfocused_borders #bcbebf;
/*
widgets main borders color insensitive */
@define-color insensitive_borders rgba(170, 173, 174, 0.35);
/****************
* Text Entries *
****************/
spinbutton:not(.vertical),
entry {
min-height: 30px;
padding-left: 8px;
padding-right: 8px;
border: 1px solid;
border-radius: 3px;
transition: all 200ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
color: #232627;
border-color: #bcbebf;
background-color: #fcfcfc;
box-shadow: none; }
treeview entry.flat, treeview entry {
border-radius: 0;
background-image: none;
background-color: #fcfcfc; }
treeview entry.flat:focus, treeview entry:focus {
border-color: #3daee9; }
ETA: Having re-read, it uses the same colors, looks like… just doesn’t reference them using the defined names. So I guess as long as they’re consistent on that, you can reference colors like @borders
or @theme_bg_color
to match them.