You are not logged in.
Hello,
with the new xfdesktop ported to gtk3, I need to port my gtk2 desktop settings to gtk3 too.
Can anyone tell me, how to setup the correct css style expressions for my gtk2 settings?
I had transparent labels for my desktop icons and tried to port all of my settings to css.
Because the lack of my css knowledge, I got it worked only partly.
The former gtk2rc file there was:
style "xfdesktop-icon-view"
{
font_name = "DejaVu Sans Book"
XfdesktopIconView::label-alpha = 0
XfdesktopIconView::selected-label-alpha = 140
XfdesktopIconView::ellipsize-icon-labels = 0
XfdesktopIconView::shadow-x-offset = 1
XfdesktopIconView::shadow-y-offset = 1
XfdesktopIconView::selected-shadow-x-offset = 1
XfdesktopIconView::selected-shadow-y-offset = 1
XfdesktopIconView::shadow-color = "#000000"
XfdesktopIconView::selected-shadow-color = "#999999"
XfdesktopIconView::cell-spacing = 5
XfdesktopIconView::cell-padding = 0
XfdesktopIconView::cell-text-width-proportion = 2.8
base[NORMAL] = "#cccccc"
base[SELECTED] = "#cccccc"
base[ACTIVE] = "#cccccc"
fg[NORMAL] = "#cccccc"
fg[SELECTED] = "#000000"
fg[ACTIVE] = "#000000"
}
widget_class "*XfdesktopIconView*" style "xfdesktop-icon-view"
widget "*XfdesktopIconView*" style "xfdesktop-icon-view"
class "*XfdesktopIconView*" style "xfdesktop-icon-view"
My new gtk.css contains the following, I figured out already:
* {
-gtk-icon-style: regular;
}
XfdesktopIconView {
font: "DejaVu Sans Book";
background-color: rgba(240, 240, 240, 0.0);
color:#cccccc;
text-shadow: 2px 2px #000000;
margin: 0;
padding: 0;
}
Transparency is working, but I don't know howto do the "active / selected - thing" and so on with this style class or whats the working css selector for this related behaviour.
Last edited by Machredsch (2017-05-17 14:19:59)
Offline
just use the gtk3 inspector on xfdesktop
pkill xfdesktop
GTK_DEBUG=interactive xfdesktop
Offline
Hello and welcome.
Here are my current xfdesktop GTK3 configs:
/* xfdesktop icon theming */
XfdesktopIconView.view {
background-color: rgba(0,0,0,0.0);
}
XfdesktopIconView.view:active {
background-color: rgba(0,0,0,0.3);
color: #3D7BC7;
border-radius: 1px;
}
XfdesktopIconView.rubberband {
background-color: rgba(0,0,0,0.3);
}
XfdesktopIconView.label:active {
background-color: rgba(0,0,0,0.3);
color: white;
}
You can tweak as necessary.
And as @sixsixfive says, you can use the inspector, but some items, like the rubberband entity, I can't get to show up in the inspector.
Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki | Community | Contribute ---
Online
Thank you, you 2 have helped me a lot.
I didn't know about that GTKInspector.
Offline
Can anybody help me with the overlay color of the desktop icons when they are active? What is the CSS selector? Many thanks in advance
Offline
Can anybody help me with the overlay color of the desktop icons when they are active? What is the CSS selector? Many thanks in advance
Hello and welcome.
Consider this block:
XfdesktopIconView.view {
background: transparent;
color: #fcfcfc;
border-radius: 3px; }
XfdesktopIconView.view:active {
background: rgba(23, 104, 189, 0.5);
text-shadow: 0 1px 1px black; }
XfdesktopIconView.view .label {
text-shadow: 1px 1px 2px black; }
The "XfdesktopIconView.view:active" block affects the actively selected icon. Is this what you are referring to when you say "overlay color"?
Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki | Community | Contribute ---
Online
Good responses. Added GTK Inspector to my Tidbits.
Last edited by Jerry3904 (2018-12-05 11:55:08)
MX-23 (based on Debian Stable) with our flagship Xfce 4.18.
Offline
Consider this block:
XfdesktopIconView.view { background: transparent; color: #fcfcfc; border-radius: 3px; } XfdesktopIconView.view:active { background: rgba(23, 104, 189, 0.5); text-shadow: 0 1px 1px black; } XfdesktopIconView.view .label { text-shadow: 1px 1px 2px black; }
The "XfdesktopIconView.view:active" block affects the actively selected icon. Is this what you are referring to when you say "overlay color"?
I tested your code but I don't think it is what I want. Let me give you an example. Let's say I have a browser bookmark (a desktop file) on my desktop. With my current theme I have stars as icons for bookmarks. If I select a bookmark the star gets darker because a semi transparent blue layer will be drawn over it. Now I want to change exactly this color.
Offline
The "highlight" color, then? What I see when I highlight text.
select text in order to copy it with CTRL C.
Regards,
MDM
Offline
. If I select a bookmark the star gets darker because a semi transparent blue layer will be drawn over it. Now I want to change exactly this color.
The code block below works for me by getting rid of the transparent layer (it also affects the text background). Which appearance theme are you using?
Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki | Community | Contribute ---
Online
The "highlight" color, then? What I see when I highlight text.
select text in order to copy it with CTRL C.
Yes, the highlighting / selection color.
Offline
The code block below works for me by getting rid of the transparent layer (it also affects the text background). Which appearance theme are you using?
I am using the Numix theme under Xubuntu 18.10 64 bit. The highlighting color for desktop items is blue but should be red.
Offline
ToZ wrote:The code block below works for me by getting rid of the transparent layer (it also affects the text background). Which appearance theme are you using?
I am using the Numix theme under Xubuntu 18.10 64 bit. The highlighting color for desktop items is blue but should be red.
How about something like this:
XfdesktopIconView.view {
background: transparent;
color: #fcfcfc;
border-radius: 3px; }
XfdesktopIconView.view:active {
background: rgba(23, 104, 189, 0.5);
text-shadow: 0 1px 1px black; }
XfdesktopIconView.view .label {
text-shadow: 1px 1px 2px black; }
...make sure you restart xfdesktop to see the change.
Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki | Community | Contribute ---
Online
Many thanks ToZ. After some trial and error I now found this solution:
XfdesktopIconView.view {
color: rgb(240, 84, 76);
}
XfdesktopIconView.label {
color: white;
}
XfdesktopIconView.view:active {
background: rgba(240, 84, 76, 0.8);
}
It's a bit confusing because in CSS the color attribute normally defines the text color. Anyway, it's working now
Offline
[ Generated in 0.012 seconds, 7 queries executed - Memory usage: 625.06 KiB (Peak: 641.91 KiB) ]