GNOME Bugzilla – Bug 788044
Themeable tab bar (merge from Ubuntu)
Last modified: 2017-10-23 19:58:14 UTC
Ubuntu, for reasons unbeknownst to me, themes gnome-terminal's tab bar differently than other apps in their default Ambiance/Radiance themes. In order to do this, they patch g-t to add some CSS classes. Should we backport these? The patch is inside https://packages.ubuntu.com/artful/gnome-terminal -> right-hand bar -> gnome-terminal_3.24.2-0ubuntu4.debian.tar.xz (or whichever the actual version is) -> patches/0001-Add-style-classes-and-CSS-names-to-some-of-our-widge.patch. This is similar to commit a0619ec, although I guess we should be consistent whether we're using CSS names or classes, I'm not sure which one's the better choice. Or, even better, shouldn't there be one "big hammer" to denote that it's a terminal window (not Prefs, About etc.) of gnome-terminal? A CSS class added to the topmost possible widget?
Ok with this. But use CSS names, not classes. And we can add one to the TerminalWindow too.
I tried setting the widget class' css name for TerminalNotebook, but this totally broke theming. And since ther toplevel widget has CSS name 'terminal-window' you can always just select from that down. So this seems unnecessary to me. -> WONTFIX ?
Created attachment 362120 [details] [review] Ambiance patch, initial try *Probably* WONTFIX. I've created the attached change to /usr/share/themes/Ambiance/gtk-3.20/apps/gnome-terminal.css as shipped by https://packages.ubuntu.com/artful/light-themes. I'm unsure about patching the very first selector as well as the one with ".maximized", but the rest should be okay. The result is _mostly_ okay. The rounded corners of the active tab don't look good, and the buttons (the X's and the New tab & Dropdown buttons) get an awful bright background on focus out. Since the patch is quite trivial and I'm pretty sure the selectors still refer to the same elements, all I can think of is a conflict with another CSS file, and (as far as I recall from HTML CSS ages ago) selectors with class matches have higher priority (or something along these lines), so the priority of some of the rules in gnome-terminal.css decreases, causing the troubles. This means that we can say WONTFIX and it's not our problem, but it's going to be nontrivial for Ubuntu adjust the theme to mainstream g-t (if they wish to).
And this also means that if we address this request, using CSS names rather than classes as per comment 1, probably Ubuntu is nowhere closer to a simple search-n-replace fix. (Just for reference: probably their patch predates our "terminal-window" CSS name, so they're absolutely not to blame for coming up with this patch at the first place.) Filed Ubuntu bug: https://bugs.launchpad.net/ubuntu/+source/light-themes/+bug/1726555. Closing as wontfix.