Xfce Forum

Sub domains
 

You are not logged in.

#1 2021-08-16 04:05:37

mykai
Member
Registered: 2021-08-14
Posts: 24

Is it possible to give the XFCE taskbars/panels rounded corners?

There are plenty of themes that make the top corners of windows rounded, but I'm not finding any that make the panel corners rounded (assuming the panel in question is in "shrink to fit" mode of course).

Is it possible to theme the panels in this way?

Last edited by mykai (2021-08-16 04:05:56)

Offline

#2 2021-08-16 10:37:50

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,128

Re: Is it possible to give the XFCE taskbars/panels rounded corners?

You can use a tweak like this in ~/.config/gtk-3.0/gtk.css:

.xfce4-panel {
   border-bottom-left-radius: 10px;
   border-bottom-right-radius: 10px;
   border-top-left-radius: 10px;
   border-top-right-radius: 10px;
}

...adjust the values to suit and restart the panel for it to take effect:

xfce4-panel -r

Note: adding transparent separators to the front and back end of the panel help to prevent widget overlap.

Offline

#3 2021-08-16 17:01:08

Skaperen
Member
From: right by Jesus, our Saviour
Registered: 2013-06-15
Posts: 564

Re: Is it possible to give the XFCE taskbars/panels rounded corners?

is the xfce4-panel command a new thing in 4.16?

Offline

#4 2021-08-16 17:26:41

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,128

Re: Is it possible to give the XFCE taskbars/panels rounded corners?

Skaperen wrote:

is the xfce4-panel command a new thing in 4.16?

It's a GTK3 tweak, so it would have been available since 4.14 - when the switch to GTK3 happened.

Offline

#5 2021-08-16 22:37:55

mykai
Member
Registered: 2021-08-14
Posts: 24

Re: Is it possible to give the XFCE taskbars/panels rounded corners?

I guess I should have been more clear, is there a way to target the panels separately? Are the different panels targetable using nth-child tricks? (I'm waiting to install the gtk inspector thing while I figure out my gradients bug)

Offline

#6 2021-08-16 23:09:46

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,128

Re: Is it possible to give the XFCE taskbars/panels rounded corners?

mykai wrote:

I guess I should have been more clear, is there a way to target the panels separately? Are the different panels targetable using nth-child tricks? (I'm waiting to install the gtk inspector thing while I figure out my gradients bug)

Unfortunately no - separate panels are not distinguishable between each other with respect to CSS.

Offline

#7 2021-08-18 01:31:33

mykai
Member
Registered: 2021-08-14
Posts: 24

Re: Is it possible to give the XFCE taskbars/panels rounded corners?

Hmmm..... CSS is fairly powerful though (assuming gtk is using the full thing and not some stripped version). How are the panels positioned internally? Like, do they get CSS position attributes attached to them at all? Can you target *[position="absolute"][top="123px"] ?

Obviously this kind of hard coding is super fragile and would break if you ever moved the panel or anything, but for my private local use I can deal with that.

Offline

#8 2021-08-18 02:06:29

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,128

Re: Is it possible to give the XFCE taskbars/panels rounded corners?

Panel positioning is managed through the xfconf backend. Have a read through this thread where that setting is discussed.

Offline

#9 2021-08-18 02:20:09

mykai
Member
Registered: 2021-08-14
Posts: 24

Re: Is it possible to give the XFCE taskbars/panels rounded corners?

OK thanks. Now that I figured out the gradient issue I'll try to start messing with this. Thanks for all your help in everything btw.

Offline

Board footer

Powered by FluxBB