1XDG-ICON-RESOURCE(1)       xdg-icon-resource Manual       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
34       http://www.freedesktop.org/wiki/Specifications/icon-theme-spec
35

COMMANDS

37       install
38           Installs the icon file indicated by icon-file to the desktop icon
39           system under the name icon-name. Icon names do not have an
40           extension. If icon-name is not provided the name is derived from
41           icon-file. The icon file must have .png or .xpm as extension. If a
42           corresponding .icon file exists in the same location as icon-file
43           it will be installed as well.
44
45       uninstall
46           Removes the icon indicated by icon-name from the desktop icon
47           system. Note that icon names do not have an extension.
48
49       forceupdate
50           Force an update of the desktop icon system. This is only useful if
51           the last call to xdg-icon-resource included the --noupdate 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 additional
57           changes will follow and that it is not necessary to update the
58           desktop icon system right away.
59
60       --novendor
61           Normally, xdg-icon-resource checks to ensure that an icon file to
62           be installed in the apps context has a proper vendor prefix. This
63           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. The
69           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 is
73           specified the icons will be installed as part of the default
74           hicolor theme. Applications may install icons under multiple themes
75           but should at least install icons for the default hicolor theme.
76
77       --context context
78           Specifies the context for the icon. Icons to be used in the
79           application menu and as desktop icon should use apps as context
80           which is the default context. Icons to be used as file icons should
81           use mimetypes as context. Other common contexts are actions,
82           devices, emblems, filesystems and stock.
83
84       --size size
85           Specifies the size of the icon. All icons must be square. Common
86           sizes for icons in the apps context are: 16, 22, 32, 48, 64 and
87           128. Common sizes for icons in the mimetypes context are: 16, 22,
88           32, 48, 64 and 128
89
90       --mode mode
91           mode can be user or system. In user mode the file is (un)installed
92           for the current user only. In system mode the file is (un)installed
93           for all users on the system. Usually only root is allowed to
94           install in system mode.
95
96           The default is to use system mode when called by root and to use
97           user mode when called by a non-root user.
98
99       --help
100           Show command synopsis.
101
102       --manual
103           Show this manual page.
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 administrator
118           to override the installation mode. Valid values are user and
119           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
126           Error in command line syntax.
127
128       2
129           One of the files passed on the command line did not exist.
130
131       3
132           A required tool could not be found.
133
134       4
135           The action failed.
136
137       5
138           No permission to read one of the files passed on the command line.
139

SEE ALSO

141       xdg-desktop-icon(1), xdg-desktop-menu(1), xdg-mime(1)
142

EXAMPLES

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

AUTHORS

159       Kevin Krammer
160           Author.
161
162       Jeremy White
163           Author.
164
166       Copyright © 2006
167
168
169
170xdg-utils 1.0                     11/05/2016              XDG-ICON-RESOURCE(1)
Impressum