Xfce Forum

Sub domains
 

You are not logged in.

#1 2010-07-20 22:01:41

the98
Member
Registered: 2009-11-10
Posts: 62

How can I change the name of the xfdesktop icons?

Hi everyone,

I have a few questions, maybe you can help me. I would to change the name of the desktop icons, for instance, intead of "Home", I would like to read "98's Home"... Is there a way to do that? Because when I right click over the icon and go to Properties, there's a textbox with the name, but I can't modify it. I use XFCE 4.6 under a Debian Squeeze system.

Another question that I have is about icon's labels. The text in the label is aligned to the left, and I would like to know if there is a way to center it, because I don't like the way it looks aligned to the left.

Anyway, thanks everyone.

Cheers,

The98

Offline

#2 2010-07-21 16:56:15

etnlWings
Member
Registered: 2007-10-30
Posts: 218

Re: How can I change the name of the xfdesktop icons?

The default Home/Filesystem icons are a bit of prefab. The only way to do what you're wanting (which I used to do, myself), is to turn off the proper Home/Filesystem/whatever/ Icons and roll your own with .desktop launchers. Luckily, I've still got backups of my home directory as old as 2007, which makes this considerably quicker.

For my old Home icon, I created a file called home.desktop in my ~/Desktop folder and added the following text to it:

[Desktop Entry]
Version=1.0
Encoding=UTF-8
Type=Application
Name=Icaria Home
Comment=Home folder
Categories=Application;
Exec=thunar
Icon=folder_home
Terminal=false
StartupNotify=false

For the Filesystem icon, you would change the exec line to thunar / and for the trash, thunar trash:/.

For the Home folder, you can also just go to the /home directory, right-click on your home folder and 'send it to the desktop', which will do the same thing. You can't do this for the filesystem, or trash icons, though.


As for the text alignment, as best I can recall, they are centred. It's only broken lines, which exhibit a left-justification.

All the controls for the icon formatting are as follows (add these to your ~/.gtkrc-2.0 file, to set them):

style "xfdesktop-icon-view" 
{
font_name="LucidaMacBold"
XfdesktopIconView::ellipsize-icon-labels = 0
XfdesktopIconView::shadow-x-offset = 1
XfdesktopIconView::shadow-y-offset = 1
XfdesktopIconView::selected-shadow-x-offset = 0
XfdesktopIconView::selected-shadow-y-offset = 0
XfdesktopIconView::shadow-color = "#080808"
XfdesktopIconView::selected-shadow-color = "#000000"
XfdesktopIconVIew::cell-spacing = 5
# spacing between each 'cell' in the grid of icons
XfdesktopIconView::cell-padding = 0
# sets extra padding placed around each icon+text
XfdesktopIconView::cell-text-width-proportion = 2.8
# the units are in width (so for 30px icons, '2.5' would leave a 75px wide area underneath for the text)
}
widget_class "*XfdesktopIconView*" style "xfdesktop-icon-view"
widget "*XfdesktopIconView*" style "xfdesktop-icon-view"
class "*XfdesktopIconView*" style "xfdesktop-icon-view"

Obviously, that's configured for my desktop. Just comment them all out and play with one at a time. Then just pass xfdesktop -r to restart xfdesktop.

Offline

#3 2010-07-22 00:46:36

the98
Member
Registered: 2009-11-10
Posts: 62

Re: How can I change the name of the xfdesktop icons?

Hi, thanks for the answer. That's a very clever way to change the names...

I've tried another one which is to create a new .mo using the .po file provided from the translation team. Estrange thing is, I've change Home, Floppy drive and File System's names, but File System doesn't change its name... It's weird.

Anyway, my labels aren't centered, this a screenshot I've made before making the changes to the icons' names.

capturadepantalla.png
Names are in Spanish because I'm from a Spanish speeking country  :razz:

Thanks again for your time.

Cheers,

The98

Offline

Board footer

Powered by FluxBB