1XDG-ICON-RESOURCE(1)                                      XDG-ICON-RESOURCE(1)
2
3
4

NAME

6       xdg-icon-resource - command line tool for (un)installing icon resources
7

SYNOPSIS

9       xdg-icon-resource install [--noupdate] [--novendor] [--theme theme]
10                         [--context context] [--mode mode] --size size
11                         icon-file [icon-name]
12
13       xdg-icon-resource uninstall [--noupdate] [--theme theme]
14                         [--context context] [--mode mode] --size size
15                         icon-name
16
17       xdg-icon-resource forceupdate [--theme theme] [--mode mode]
18
19       xdg-icon-resource {--help --manual --version}
20

DESCRIPTION

22       The xdg-icon-resource program can be used to install icon resources
23       into the desktop icon system in order to illustrate menu entries, to
24       depict desktop icons or to graphically represent file types.
25
26       The desktop icon system identifies icons by name. Depending on the
27       required size, the choice of icon theme and the context in which the
28       icon is used, the desktop icon system locates an appropriate icon
29       resource to depict an icon. Icon resources can be XPM files or PNG
30       files.
31
32       The desktop icon system works according to the XDG Icon Theme
33       Specification at http://www.freedesktop.org/Standards/icon-theme-spec
34

COMMANDS

36       install
37              Installs the icon file indicated by icon-file to the desktop
38              icon system under the name icon-name. Icon names do not have an
39              extension. If icon-name is not provided the name is derived from
40              icon-file. The icon file must have .png or .xpm as extension. If
41              a corresponding .icon file exists in the same location as
42              icon-file it will be installed as well.
43
44       uninstall
45              Removes the icon indicated by icon-name from the desktop icon
46              system. Note that icon names do not have an extension.
47
48       forceupdate
49              Force an update of the desktop icon system. This is only useful
50              if the last call to xdg-icon-resource included the --noupdate
51              option.
52

OPTIONS

54       --noupdate
55              Postpone updating the desktop icon system. If multiple icons are
56              added in sequence this flag can be used to indicate that
57              additional changes will follow and that it is not necessary to
58              update the desktop icon system right away.
59
60       --novendor
61              Normally, xdg-icon-resource checks to ensure that an icon file
62              to be installed in the apps context has a proper vendor prefix.
63              This option can be used to disable that check.
64
65              A vendor prefix consists of alpha characters ([a-zA-Z]) and is
66              terminated with a dash ("-"). Companies and organizations are
67              encouraged to use a word or phrase, preferably the organizations
68              name, for which they hold a trademark as their vendor prefix.
69              The purpose of the vendor prefix is to prevent name conflicts.
70
71       --theme theme
72              Installs or removes the icon file as part of theme. If no theme
73              is specified the icons will be installed as part of the default
74              hicolor theme. Applications may install icons under multiple
75              themes but should at least install icons for the default hicolor
76              theme.
77
78       --context context
79              Specifies the context for the icon. Icons to be used in the
80              application menu and as desktop icon should use apps as context
81              which is the default context. Icons to be used as file icons
82              should use mimetypes as context. Other common contexts are
83              actions, devices, emblems, filesystems and stock.
84
85       --size size
86              Specifies the size of the icon. All icons must be square. Common
87              sizes for icons in the apps context are: 16, 22, 32, 48, 64 and
88              128. Common sizes for icons in the mimetypes context are: 16,
89              22, 32, 48, 64 and 128
90
91       --mode mode
92              mode can be user or system. In user mode the file is
93              (un)installed for the current user only. In system mode the file
94              is (un)installed for all users on the system. Usually only root
95              is allowed to install in system mode.
96
97              The default is to use system mode when called by root and to use
98              user mode when called by a non-root user.
99
100       --help Show command synopsis.
101
102       --manual
103              Show this manualpage.
104
105       --version
106              Show the xdg-utils version information.
107

ENVIRONMENT VARIABLES

109       xdg-icon-resource honours the following environment variables:
110
111       XDG_UTILS_DEBUG_LEVEL
112              Setting this environment variable to a non-zero numerical value
113              makes xdg-icon-resource do more verbose reporting on stderr.
114              Setting a higher value increases the verbosity.
115
116       XDG_UTILS_INSTALL_MODE
117              This environment variable can be used by the user or
118              administrator to override the installation mode. Valid values
119              are user and system.
120

EXIT CODES

122       An exit code of 0 indicates success while a non-zero exit code
123       indicates failure. The following failure codes can be returned:
124
125       1      Error in command line syntax.
126
127       2      One of the files passed on the command line did not exist.
128
129       3      A required tool could not be found.
130
131       4      The action failed.
132
133       5      No permission to read one of the files passed on the command
134              line.
135

SEE ALSO

137       xdg-desktop-icon(1), xdg-desktop-menu(1), xdg-mime(1)
138

EXAMPLES

140       To install an icon resource to depict a launcher for the application
141       myfoobar, the company ShinyThings Inc. can use:
142
143       xdg-icon-resource install --size 64 shinythings-myfoobar.png
144
145
146       To install an icon for a new application/x-foobar file type one can
147       use:
148
149       xdg-icon-resource install --context mimetypes --size 48 ./mime-foobar-48.png application-x-foobar
150       xdg-icon-resource install --context mimetypes --size 64 ./mime-foobar-64.png application-x-foobar
151
152       This will install two icons with the name application-x-foobar but with
153       different sizes.
154

AUTHOR

156       Kevin Krammer, Jeremy White.
157       <kevin.krammer@gmx.at>
158       <jwhite@codeweavers.com>
159
160
161
162xdg-utils 1.0                     06/24/2007              XDG-ICON-RESOURCE(1)
Impressum