PDA

View Full Version : [xfce] GTK2/3 customizations



loceka2
September 29th, 2016, 10:46 AM
Hello,

I have two issues that can be resolved by customizing the GTK settings (I think), but I'm not skilled enough with GTK and my researches didn't help.

The first issue concerns the XFCE4 "pager" (workspace switcher) in the taskbar, which is way too wide when using multiple screens (there are several posts related to this issue over the net but with no solution).
I've seen in this post (https://ubuntuforums.org/showthread.php?t=1945518&p=11787469#post11787469) that the colors could be changed (and it works for me too) so I wondered if the size could also be tweaked, and how? I couldn't find the matching instructions.

The second issue concerns the XFCE4 Vertex Maia theme which is almost perfect expect for the button selection : there is no hint a button is selected which is very disturbing when using TAB navigation.

Here is a screenshot of buttons using the Vertex Maia Dark theme:
271422

And here is a screenshot of the same screen using the XFCE Dusk theme:
271421

As you can see, the latter hints which button is currently selected, as anyone would expect.

Is there a way to change the settings in order to add such a hint in that theme ?
I guess it uses xfwm4 but I have no clue what it implies regarding the customization...

Thanks in advance,
Loceka.

kc1di
September 29th, 2016, 11:17 AM
Hello loceka2 and welcome to XFCE and Ubuntu,
you can change the size of the switcher or I should say the style by following this post.
hope it may be of help to you.
http://askubuntu.com/questions/744046/can-the-size-of-the-workspace-switcher-applet-be-changed

vasa1
September 29th, 2016, 11:20 AM
... As you can see, the latter hints which button is currently selected, as anyone would expect.

Is there a way to change the settings in order to add such a hint in that theme ?
I guess it uses xfwm4 but I have no clue what it implies regarding the customization...

Thanks in advance,
Loceka.
If the gtkrc file of your theme has a line like
GtkWidget ::focus-line-width = 0
you could change it to 1 or 2 from 0 and hope for the best.

xfwm4 is the window manager and I don't think it influences how selected buttons appear in your example.

loceka2
September 29th, 2016, 01:46 PM
Hello loceka2 and welcome to XFCE and Ubuntu,
you can change the size of the switcher or I should say the style by following this post.
hope it may be of help to you.
http://askubuntu.com/questions/744046/can-the-size-of-the-workspace-switcher-applet-be-changed

Hello and thank you !
It's not quite what I was asking for, since it changes the behaviour of the tool (the workspace contents are no longer displayed) but it will do if I can find no way to tune it.


If the gtkrc file of your theme has a line like
GtkWidget ::focus-line-width = 0
you could change it to 1 or 2 from 0 and hope for the best.

Hoping wasn't enough I fear.
I've declared it in both ~/.gtkrc-2.0 and ~/.config/gtk-3.0/settings.ini with no result.

I've also added -GtkWidget-focus-line-width:1 (https://developer.gnome.org/gtk3/stable/gtk-migrating-GtkStyleContext-parser-extensions.html) to /usr/share/themes/Vertex-Maia/gtk-3.0/gtk-dark.css but without any visible improvement.
The file /usr/share/themes/Vertex-Maia/gtk-2.0/gtkrc already declared GtkWidget::focus-line-width = 1.

Of course I restarted X (and even rebooted) between each operation.

vasa1
September 29th, 2016, 05:01 PM
https://github.com/horst3180/vertex-theme/issues/197

BTW, the Vertex themes aren't readily amenable to customization just by editing the css files.

loceka2
September 30th, 2016, 09:23 AM
Thank you for pointing out that it was a GTK2-only issue.
Indeed in GTK3 applications (in paman at least), the focused button is highlighted.

I still can't see how to fix it for the GTK2 apps though.