6

On a fresh Ubuntu, you usually have these default (empty) folders:

  • Downloads
  • Documents
  • Music
  • Videos
  • ...

all with special emblems.

BUT, where are these Emblems coming from?, what's telling Nautilus to display these emblems? Now that Nautilus has dropped Emblems support, I am unable to inspect or change these emblems via GUI. Just being curious here...

Update

As I posted as comment to Uri's answer: everyone here, is right: I was confusing emblems with folder-specific icons in this case. But: let me rephrase my question:

Why does, for example, Nautilus know that it has to apply a special icon for these directories? Is there some flag on the actual dir, a metadata field in GVFS or is this hard-coded into Nautilus?

(running Ubuntu 12.04.1)

2
  • 1
    I know it does not answer the question but I assumed you would be more interested in adding emblems back into Nautilus ;)
    – Rinzwind
    Jan 1, 2013 at 21:21
  • 2
    I'm pretty sure you're confusing emblems with just the Icon identifying the Folder. Jan 1, 2013 at 21:32

4 Answers 4

3

Those are not emblems, in the image below you can see that the emblems are located in the lower right part of the Item (in this case is a symlink/shortcut).

The Icons for the user folders usually have a little representation of what that folder is all about. Those folders are "special" and are different from the rest of the folders on your system. In this example the folder is Shared/Public stuff, next to this is a regular folder.

Icons are located in two locations:

  1. ~/.icons
  2. /usr/share/icons

Depending on the the icon theme, they will placed in different categories (most are in /places).

This will help you understand it better:

Image


Why does, for example, Nautilus know that it has to apply a special icon for these directories? Is there some flag on the actual dir, a metadata field in GVFS or is this hard-coded into Nautilus?

It's a standard set by the freedesktop organization called xdg-user-dirs.

From the site:

xdg-user-dirs is a tool to help manage "well known" user directories like the desktop folder and the music folder. It also handles localization (i.e. translation) of the filenames.

The way it works is that xdg-user-dirs-update is run very early in the login phase.

This program reads a configuration file, and a set of default directories. It then creates localized versions of these directories in the users home directory and sets up a config file in $(XDG_CONFIG_HOME)/user-dirs.dirs (XDG_CONFIG_HOME defaults to ~/.config) that applications can read to find these directories.

You can read more about the XDG Base Directory Specification here.

2
  • You, as everyone here, is right: I was confusing emblems with folder-specific icons here. But: let me rephrase my question: Why does, for example, Nautilus know that it has to apply a special icon for these directories? Is there some flag on the actual dir, a metadata field in GVFS or is this hard-coded into Nautilus?
    – isync
    Jan 2, 2013 at 1:41
  • The part about xdg-user-dirs answered the question.
    – isync
    Jan 22, 2013 at 13:57
2

The icons are determined by the desktop-theme you are using- you can find them under /usr/share/icons/<ThemeName>/places

With Humanity that would then be /usr/share/icons/Humanity/places

1
  • I found the icons I was looking for only in /usr/share/icons/Humanity/places/64, but not in /usr/share/icons/Humanity/places/128 neither in /usr/share/icons/Humanity/places/scalable May 17, 2017 at 9:39
2

At least in 13.04, they are emblems, and they can be changed. Changing the icon gets rid of the folder, which for me wasn't what was desired.

I only had a handful of folders I wanted to do this to, so I didn't feel I needed the gui tools. Also, none of them worked for me in 13.04 (which I realize isn't what you have). The below did.

gvfs-set-attribute -t stringv file_name metadata::emblems emblem_name default

You can find the possible short names and the images that are applied with them in /usr/share/icons/Humanity/emblems (if you are using the default icon theme, otherwise look in your custom icon theme.)

For example, I did:

gvfs-set-attribute -t stringv ~/Sites metadata::emblems marketing art
1
  • Icons, emblems... Seems to have changed over versions. Anyway, what you describe works to "emblemize" folders from cli. Thanks!
    – isync
    Oct 13, 2013 at 12:45
1

You can use the Emblemize script to edit and inspect emblems (works with 11.10 and 12.04)

Installation

sudo add-apt-repository ppa:dr3mro/nautilus-actions-extra
sudo apt-get update
sudo apt-get install nautilus-actions nautilus-actions-extra nautilus-gksu

Re-start Nautilus...

nautilus -q

Result:

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .