xdg-utils xdg-icon-resource's destination icon name

James Richard Tyrer tyrerj at acm.org
Sun Jun 17 15:23:49 PDT 2007

Daniel Yek wrote:
> Hi,
> xdg-icon-resource requires that the (source) icon has vendor-prefix and 
> turns around copies the icon to a destination file without the 
> vendor-prefix -- in fact, using only MIME type as icon file name. This 
> creates bigger icon name conflicts. Is that a design decision or a bug?
> So, an icon likes hxplay-mime-video-ogg-48x48.png would be installed as 
> video-ogg.png (with symbolic link of gnome-mime-video-ogg.png to it). 
> That is undesirable to me. Documentation says nothing about behavior 
> like this, leaving developers reading through the scripts to figure out 
> if the scripts are doing what is expected (if what is expected is 
> understood at all). So, xdg-utils doesn't make life easier as it first 
> appeared to be. (If it is documented clearly, it could be a different 
> story.)
> Also, xdg-icon-resource doesn't provide an option to create only 
> symbolic links back to icons in application installation directory.
> Any comment if xdg-icon-resource is right or wrong? Was it done that way 
> to accommodate how KDE worked? (Just speculating...)

This is an inherent problem.  It does not appear to be a bug that can be 
fixed.  MIME type icons are used mostly by file managers.  So, there can 
only be one icon per MIME type for a given icon theme.

If apps are built for a specific DeskTop then the solution for icon 
themes supplied by that desktop is to coordinate with the DeskTop.

With common icon themes such as Tango, the solution to the problem is to 
coordinate with the Tango project.

This leaves apps that are not built for a specific DeskTop and yet need 
to install MIME type icons specific to that application.  These icons 
are going to be installed as HiColor and it is possible that other 
applications may also install them there or that the DeskTop supplies an 
icon for that MIME type in the HiColor theme.

It is this last case that is the problem and it does need to be solved.

One solution is to start a HiColor project so that there will exist a 
standard set of HiColor icons.  Then, although we may have more than one 
application installing the same icon, at least it will be the same icon.

Another possibility (which I don't think is a good idea, but it is a 
logical idea) deals first with how to install icons with the same name 
and icon theme.  We treat the "hicolor" directory as a name space with 
inheritance.  So, we have:


This would solve the problem of where to put them.  The question then 
becomes how to use them.

Please suggest your best ideas.  Fortunately, this problem isn't really 
going to be a big issue till shipping stable releases of KDE and GNOME 
are using the same names for all icons.


More information about the xdg mailing list