Xfce Forum

Sub domains
 

You are not logged in.

#1 2017-12-23 00:08:57

Yupy
Member
Registered: 2017-12-23
Posts: 3

Desktop Icon Spacing

I know this is an old topic I didn't wanted to create a double post.

I want to lower the vertical icons spacing on the desktop icons, I'm using Linux Mint 18.3 XFCE (I guess is the latest version of xfce) I tried the above didn't worked I found something similar on the net also not working maybe because of old posts.

TY!

Offline

#2 2017-12-23 00:19:57

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 10,948

Re: Desktop Icon Spacing

Hello and welcome.

I split your post off to it's own thread. You posted in one that was 11 years old - a lot has changed since then.

Desktop icon spacing in te GTK2 version of xfdesktop can be affected via gtk overrides. They are documented here. Specifically the "cell-spacing". "cell-padding", and "cell-text-width-proportion" settings.


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 ---

Offline

#3 2017-12-23 01:02:03

Yupy
Member
Registered: 2017-12-23
Posts: 3

Re: Desktop Icon Spacing

Ty for the reply @ToZ!

It worked I edited the main.rc file from the gtk-2.0 theme dir.

Much appreciated!

Last edited by Yupy (2017-12-23 01:12:59)

Offline

#4 2018-01-15 00:18:04

Yupy
Member
Registered: 2017-12-23
Posts: 3

Re: Desktop Icon Spacing

Hello, I updated the xfdesktop to xfdesktop-gtk3 and many others is there a way that I can use this:

style "xfdesktop-icon-view" {
  XfdesktopIconView::label-alpha = 0
  XfdesktopIconView::selected-label-alpha = 100
  XfdesktopIconView::shadow-x-offset = 0
  XfdesktopIconView::shadow-y-offset = 1
  XfdesktopIconView::selected-shadow-x-offset = 0
  XfdesktopIconView::selected-shadow-y-offset = 1
  XfdesktopIconView::shadow-color = "#000000"
  XfdesktopIconView::selected-shadow-color = "#000000"
  XfdesktopIconView::shadow-blur-radius = 2
  XfdesktopIconView::cell-spacing = 2
  XfdesktopIconView::cell-padding = 2
  XfdesktopIconView::cell-text-width-proportion = 1.7

  fg[NORMAL] = @selected_fg_color
  fg[ACTIVE] = @selected_fg_color
}

This is what removes the gap:

  XfdesktopIconView::cell-spacing = 2
  XfdesktopIconView::cell-padding = 2
  XfdesktopIconView::cell-text-width-proportion = 1.7

To work with GTK3 in order to reduce the spacing from the desktop icons?

Last edited by Yupy (2018-01-15 02:09:05)

Offline

#5 2018-01-16 01:52:51

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 10,948

Re: Desktop Icon Spacing

I would have thought that something like:

-XfdesktopIconView-cell-spacing: 2px;

...would have worked (like something similar in xfce4-panel), but it doesn't. I can't figure out how to control those options through GTK3 - maybe they weren't migrated.

Perhaps you could open a bug report against xfdesktop and one of the developers could provide some insight.


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 ---

Offline

#6 2018-01-18 21:26:06

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 10,948

Re: Desktop Icon Spacing

My bad. Here are the settings in GTK3 (~/.config/gtk-3.0/gtk.css):

* {
-XfdesktopIconView-cell-spacing: 2px;
-XfdesktopIconView-cell-padding: 2px;
-XfdesktopIconView-text-width-proportion: 1.7;
}

(I was missing the "*{ } ")


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 ---

Offline

#7 2021-07-03 22:51:03

gce
Member
Registered: 2021-07-03
Posts: 1

Re: Desktop Icon Spacing

Hi ToZ, just signed up to correct the CSS selector to

.view, iconview

, like so:

.view, iconview {
-XfdesktopIconView-cell-spacing: 6; /* inside item, icon to text space */
-XfdesktopIconView-cell-padding: 8; /* space between items */
-XfdesktopIconView-cell-text-width-proportion: 1.6;
-XfdesktopIconView-label-radius: 1.4;
}

(these are my settings, nevermind the values.)

The problem I encountered when using a catch-all selector like * is having every application take 1 to 2 seconds longer to open.  It seems like GTK is applying the properties to every selector it can find, which would make technical sense and be the correct behavior for *.

Anyway, just for the sake of postmortem completeness: I discovered this by peeking at my current XFCE theme located in /usr/share/themes/.../gtk-3.0/gtk.css, was trying to find a way to shed the notorious slow down in app start up times. 

Cheers.  I know this is an old thread but it is also the most accurate result on duckduckgo so, there you go.

Last edited by gce (2021-07-03 22:54:46)

Offline

#8 2021-07-03 23:31:46

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 10,948

Re: Desktop Icon Spacing

You are right. I corrected this in a later thread and indicated that you could also use the "XfdesktopIconView.view" selector, but ".view, iconview" should also work.

Thanks for the correction and welcome to the forum.


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 ---

Offline

Board footer

Powered by FluxBB