Xfce Forum

Sub domains
 

You are not logged in.

#1 2025-02-25 11:25:36

dselen
Member
Registered: 2025-01-06
Posts: 12
Windows 10Firefox 135.0

Adding padding or margins to panels that are positioned

Hello all,

I am trying to add some padding to one of my panels which is locked in position 9. But nothing seems to budge. My gtk.css is:

.xfce4-panel.horizontal {
    border-radius: 10px;
}

panel#panel-2 {
    margin-top: 50px;
}

but trying to target panel-2 do not work.

Does anyone have tips?

Last edited by dselen (2025-02-25 11:25:55)

Offline

#2 2025-02-25 13:17:46

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 11,815
LinuxFirefox 134.0

Re: Adding padding or margins to panels that are positioned

What version of xfce4-panel are you running?

For the first entry, you need to separate ".xfce4-panel" and ".horizontal" - they are two different hierarchical style classes. Also, depending on which items you have on the panel, not all might be affected by the "border-radius" setting.

As for the second one, you need at least xfce4-panel 4.19.4 and the "panel-2" designation is a style class, so:

.panel-2 {margin-top: 50px}

...but the panel class alone does not support margins, you need to target something below the panel, like:

.panel-2 .horizontal {margin-top: 50px}

Mark solved threads as [SOLVED] to make it easier for others to find solutions.
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#3 2025-03-26 13:58:55

dselen
Member
Registered: 2025-01-06
Posts: 12
Windows 10Firefox 128.0

Re: Adding padding or margins to panels that are positioned

Thank you Toz, I will test with it.

Offline

Registered users online in this topic: 0, guests: 1
[Bot] ClaudeBot

Board footer

Powered by FluxBB
Modified by Visman

[ Generated in 0.010 seconds, 7 queries executed - Memory usage: 525.23 KiB (Peak: 530.66 KiB) ]