2

As a standard desktop I use Mate on all my computers with different GNU/Linux distributions and FreeBSD. I have recently upgraded a laptop running Manjaro from Mate-1.16.1 to Mate-1.18.0.

With Mate-1.16.1 my desktop looked like this:

Mate-1.16.1 desktop

Notice that the background of the selected workspace on the bottom bar is a solid colour. In the bottom bar, the current active terminal window is shown as a rectangle with a darker background, which is also a solid colour. The same darker background colour is used to highlight menu items in the top menu.

With Mate-1.18.0 my desktop looks like this:

Mate-1.18.0 desktop

Now both the background of the chosen workspace and the background of the active window in the bottom bar use a gradient with a slightly darker colour. The highlighted items in the top menu (not shown in the picture) also use a gradient.

This difference in colour seems related to the Mate version and not to the desktop theme. I have the first style (solid background) in all my systems using an older Mate version (FreeBSD, Debian 7). I have the second style (darker gradient background) in all the systems using the newer Mate version (Manjaro, Arch, Void).

I have tried to switch the style back after the upgrade to the new Mate version but I cannot find any options related to the backgrounds of the elements I have indicated above (selected workspace, selected window, selected menu item).

So is there such an option that allows to change the style or is the new style hard-coded in Mate?

  • The changes in appearance might be related to the desktop components now depend on GTK3+ only, according to the release note of MATE 1.18. I suppose you should look for theme files in /usr/share/themes/THEME/gtk-3.0 and not gtk-2.0. – clearkimura Apr 20 '17 at 15:13
  • @clearkimura: Thanks a lot for the hint, but I think that changing the implementation should not change the behaviour. I have removed the gtk-2.0 folder for my theme and restarted the system, but nothing has changed: I still have backgrounds with a gradient instead of a solid colour. Do you think this may be a regression bug? – Giorgio Apr 20 '17 at 21:07
  • I mean, theme files provided by gtk-3.0 differ from gtk-2.0 in terms of colour shade or even the colour itself. What is the name of theme used by both MATE 1.16 and 1.18? – clearkimura Apr 21 '17 at 4:52
  • @clearkimura: My theme is BlueMenta but the behaviour has changed consistently for other themes, e.g. Menta. – Giorgio Apr 21 '17 at 7:43
1

MATE is now using GTK+ 3, according to the release note of MATE 1.18, which is likely the reason why the appearance of MATE desktop has changed regardless of the theme.

  • The entire MATE Desktop suite of applications and components is now GTK3+ only!
    • Requires GTK+ >= 3.14.
    • All GTK2+ code has been dropped [...]

Direct answers

This difference in colour seems related to the Mate version and not to the desktop theme.

The recent version of MATE uses GTK+ 3, which means the desktop theme is now using GTK+ 3 theme and not GTK+ 2 anymore. There is no changes to the theme's background colour itself #accd8a for Menta. So the colour gradient is one of the differences between GTK+ 2 and GTK+ 3 themes of the particular theme.

I cannot find any options related to the backgrounds of the elements I have indicated above (selected workspace, selected window, selected menu item).

There is no such option by default, regardless of desktop environment. Those detailed configurations are specified in the theme files.

So is there such an option that allows to change the style...

No, or at least I haven't heard any to this answered date.

...or is the new style hard-coded in Mate?

No, the theme is not hard-coded in MATE. The GTK+ 3 theme files can be found in /usr/share/themes/THEME/gtk-3.0 directory of THEME. In newer version of the theme, configuration for MATE desktop components is specified in ../mate-applications.css file.

Extended answer

When looking into mate-applications.css file, the relevant parts can be found by using gradient as keyword. Open the file in a text editor and find using the keyword.

For example, workspace switcher part in Menta theme:

/* selected WnckPager */
PanelApplet.wnck-applet .wnck-pager:selected {
    background-image: linear-gradient(to bottom,
                                      @theme_selected_bg_color,
                                      shade (@theme_selected_bg_color, 0.36));
}

The part can be just modified to without the gradient. To begin with, remove linear-gradient(,,) part and leave only the shade() and replace background-image with background-color (more details in GTK+ CSS: GTK+ 3 Reference Manual). Then, it will look like this:

/* selected WnckPager */
PanelApplet.wnck-applet .wnck-pager:selected {
    background-color: shade (@theme_selected_bg_color, 0.36);
}

To see the changes, open Appearance settings in MATE, select any other theme, then select again the last used theme i.e. Menta. No need to log out or restart, just need to reselect the theme. Do similarly for other desktop components i.e. panel menu bar, panel applet, etc.

To prevent loss of modified theme, user should create a copy of existing theme with new name i.e. Menta-custom and put in /usr/share/themes. This will make the theme independent and persists between system upgrades.

Disclaimer: I do not use MATE desktop, and I had no time to setup MATE 1.18 for testing; however, theme customization is similarly applicable to other GTK+ environment such as Xfce.

TL;DR The only way to customize the theme to meet user preference, such as removing the colour gradient, is to manually configure the files provided by the theme.

  • Thanks! I managed to change the background of the workspace switcher. The rest I can figure out myself, I guess: I just need to find the appropriate entries in the style sheet. As I side note, I do not understand WHY ON EARTH they changed the style of the themes instead of introducing new themes with the new styles!! This just produces extra useless work for people who finds an existing style OK. Anyway, many thanks! – Giorgio Apr 25 '17 at 19:29
  • Regarding shade(): the value 1.0 gives the original colour; 0.9 or less gives darker tone and 1.1 or more gives lighter tone. The closest matching colour to @selected_bg_color in Menta GTK+ 2 would be 0.6. – clearkimura Apr 26 '17 at 5:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.