summaryrefslogtreecommitdiff
path: root/scripts/html
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/html')
-rw-r--r--scripts/html/xdg-desktop.html88
-rw-r--r--scripts/html/xdg-icon.html79
-rw-r--r--scripts/html/xdg-menu.html259
3 files changed, 0 insertions, 426 deletions
diff --git a/scripts/html/xdg-desktop.html b/scripts/html/xdg-desktop.html
deleted file mode 100644
index 3e96d88..0000000
--- a/scripts/html/xdg-desktop.html
+++ /dev/null
@@ -1,88 +0,0 @@
-<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>xdg-desktop</title><meta name="generator" content="DocBook XSL Stylesheets V1.68.1"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en"><a name="xdg-desktop"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>xdg-desktop &#8212; command line tool for (un)installing icons to the desktop</p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><div class="cmdsynopsis"><p><code class="command">xdg-desktop</code> install [<code class="option">--vendor <em class="replaceable"><code>vendor-id</code></em></code>] <em class="replaceable"><code>FILE</code></em> </p></div><div class="cmdsynopsis"><p><code class="command">xdg-desktop</code> uninstall [<code class="option">--vendor <em class="replaceable"><code>vendor-id</code></em></code>] <em class="replaceable"><code>FILE</code></em> </p></div><div class="cmdsynopsis"><p><code class="command">xdg-desktop</code> { <code class="option">--help</code> | <code class="option">--manual</code> | <code class="option">--version</code> }</p></div></div><div class="refsect1" lang="en"><a name="description"></a><h2>Description</h2><p>
- The xdg-desktop program can be used to install an application launcher
- or other file on the desktop of the current user.
- </p><p>
- An application launcher is represented by a *.desktop file.
- Desktop files are defined by the freedesktop.org Desktop Entry
- Specification. The most important aspects of *.desktop files
- are summarized below.
- </p></div><div class="refsect1" lang="en"><a name="commands"></a><h2>Commands</h2><div class="variablelist"><dl><dt><span class="term">install</span></dt><dd>
- Installs <em class="replaceable"><code>FILE</code></em> to the desktop of the current user.
- </dd><dt><span class="term">uninstall</span></dt><dd>
- Removes <em class="replaceable"><code>FILE</code></em> from the desktop
- of the current user.
- </dd></dl></div></div><div class="refsect1" lang="en"><a name="options"></a><h2>Options</h2><div class="variablelist"><dl><dt><span class="term"><code class="option">--vendor</code> <em class="replaceable"><code>vendor-id</code></em></span></dt><dd>
- Adds <em class="replaceable"><code>vendor-id</code></em> as a prefix when installing desktop
- files.
- </dd><dt><span class="term"><code class="option">--help</code></span></dt><dd>
- Show command synopsis.
- </dd><dt><span class="term"><code class="option">--manual</code></span></dt><dd>
- Show this manualpage.
- </dd><dt><span class="term"><code class="option">--version</code></span></dt><dd>
- Show the xdg-utils version information.
- </dd></dl></div></div><div class="refsect1" lang="en"><a name="desktopfiles"></a><h2>Desktop Files</h2><p>
- An application launcher can be added to the desktop by installing a
- *.desktop file. A *.desktop file consists of a
- <span class="emphasis"><em>[Desktop Entry]</em></span> header followed by several
- <em class="replaceable"><code>Key</code></em>=<em class="replaceable"><code>Value</code></em> lines.
- </p><p>
- A *.desktop file can provide a name and description for an application
- in several different languages. This is done by adding a language
- code as used by LC_MESSAGES in square brackets behind the
- <em class="replaceable"><code>Key</code></em>. This way one can specify different
- values for the same <em class="replaceable"><code>Key</code></em> depending on the
- currently selected language.
- </p><p>
- The following keys are often used:
- </p><div class="variablelist"><dl><dt><span class="term">Value=1.0</span></dt><dd>
- This is a mandatory field to indicate that the *.desktop file
- follows the 1.0 version of the specification.
- </dd><dt><span class="term">Type=Application</span></dt><dd>
- This is a mandatory field that indicates that the *.desktop file
- describes an application launcher.
- </dd><dt><span class="term">Name=<em class="replaceable"><code>Application Name</code></em></span></dt><dd>
- The name of the application.
- For example <span class="emphasis"><em>Mozilla</em></span>
- </dd><dt><span class="term">GenericName=<em class="replaceable"><code>Generic Name</code></em></span></dt><dd>
- A generic description of the application.
- For example <span class="emphasis"><em>Web Browser</em></span>
- </dd><dt><span class="term">Comment=<em class="replaceable"><code>Comment</code></em></span></dt><dd>
- Optional field to specify a tooltip for the application.
- For example <span class="emphasis"><em>Visit websites on the Internet</em></span>
- </dd><dt><span class="term">Icon=<em class="replaceable"><code>Icon File</code></em></span></dt><dd>
- The icon to use for the application. This can either be
- an absolute path to an image file or an icon-name.
- If an icon-name is provided an image lookup by name is done
- in the user's current icon theme. The <span><strong class="command">xdg-icon</strong></span>
- command can be used to install image files into icon themes.
- The advantage of using an icon-name instead of an absolute
- path is that with an icon-name the application icon can be
- provided in several different sizes as well as in several
- differently themed styles.
- </dd><dt><span class="term">Exec=<em class="replaceable"><code>Command Line</code></em></span></dt><dd>
- The command line to start the application. If the application
- can open files the %f placeholder should be specified. When
- a file is dropped on the application launcher the %f is replaced
- with the file path of the dropped file. If multiple files
- can be specified on the command line the %F placeholder should
- be used instead of %f. If the application is able to open URLs
- in addition to local files then %u or %U can be used instead
- of %f or %F.
- </dd></dl></div><p>
- For a complete oveview of the *.desktop file format please
- visit http://www.freedesktop.org/wiki/Standards/desktop-entry-spec
- </p></div><div class="refsect1" lang="en"><a name="exitcodes"></a><h2>Exit Codes</h2><p>
- An exit code of 0 indicates success while a non-zero exit code
- indicates failure. The following failure codes can be returned:
- </p><div class="variablelist"><dl><dt><span class="term"><code class="option">1</code></span></dt><dd>
- Error in command line syntax.
- </dd><dt><span class="term"><code class="option">2</code></span></dt><dd>
- One of the files passed on the command line did not exist.
- </dd><dt><span class="term"><code class="option">3</code></span></dt><dd>
- A required tool could not be found.
- </dd><dt><span class="term"><code class="option">4</code></span></dt><dd>
- The action failed.
- </dd></dl></div></div><div class="refsect1" lang="en"><a name="seealso"></a><h2>See Also</h2><p><span class="citerefentry"><span class="refentrytitle">xdg-icon</span>(1)</span>
- </p></div><div class="refsect1" lang="en"><a name="examples"></a><h2>Examples</h2><p>
- TBD
- </p></div></div></body></html>
diff --git a/scripts/html/xdg-icon.html b/scripts/html/xdg-icon.html
deleted file mode 100644
index fa7dbae..0000000
--- a/scripts/html/xdg-icon.html
+++ /dev/null
@@ -1,79 +0,0 @@
-<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>xdg-icon</title><meta name="generator" content="DocBook XSL Stylesheets V1.68.1"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en"><a name="xdg-icon"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>xdg-icon &#8212; command line tool for (un)installing icons</p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><div class="cmdsynopsis"><p><code class="command">xdg-icon</code> install [<code class="option">--noupdate</code>] [<code class="option">--theme <em class="replaceable"><code>theme</code></em></code>] [<code class="option">--context <em class="replaceable"><code>context</code></em></code>] [<code class="option">--size <em class="replaceable"><code>size</code></em></code>] { <code class="option">--user</code> | <code class="option">--system</code> } <em class="replaceable"><code>icon-file</code></em> [<em class="replaceable"><code>icon-name</code></em>]</p></div><div class="cmdsynopsis"><p><code class="command">xdg-icon</code> uninstall [<code class="option">--noupdate</code>] [<code class="option">--theme <em class="replaceable"><code>theme</code></em></code>] [<code class="option">--context <em class="replaceable"><code>context</code></em></code>] [<code class="option">--size <em class="replaceable"><code>size</code></em></code>] { <code class="option">--user</code> | <code class="option">--system</code> } <em class="replaceable"><code>icon-name</code></em> </p></div><div class="cmdsynopsis"><p><code class="command">xdg-icon</code> forceupdate [<code class="option">--theme <em class="replaceable"><code>theme</code></em></code>] { --user | --system }</p></div><div class="cmdsynopsis"><p><code class="command">xdg-icon</code> { <code class="option">--help</code> | <code class="option">--manual</code> | <code class="option">--version</code> }</p></div></div><div class="refsect1" lang="en"><a name="description"></a><h2>Description</h2><p>
- The xdg-icon program can be used to install icons into the desktop
- icon system for use in menu entries, as desktop icons or as file icon.
- </p><p>
- The desktop icon system works according to the
- XDG Icon Theme Specification at
- http://www.freedesktop.org/Standards/icon-theme--spec
- </p></div><div class="refsect1" lang="en"><a name="commands"></a><h2>Commands</h2><div class="variablelist"><dl><dt><span class="term">install</span></dt><dd>
- Installs the icon file indicated by <em class="replaceable"><code>icon-file</code></em>
- to the desktop icon system under the name
- <em class="replaceable"><code>icon-name</code></em>. If
- <em class="replaceable"><code>icon-name</code></em> is not provided the name is
- derived from <em class="replaceable"><code>icon-file</code></em>.
- The icon file must have
- <span class="emphasis"><em>.png</em></span>, <span class="emphasis"><em>.xpm</em></span> or
- <span class="emphasis"><em>.svg</em></span> as extension. If a corresponding
- <span class="emphasis"><em>.icon</em></span> file exists in the same location as <em class="replaceable"><code>icon-file</code></em>
- it will be installed as well.
- </dd><dt><span class="term">uninstall</span></dt><dd>
- Removes the icon file indicated by <em class="replaceable"><code>icon-name</code></em>
- from the desktop icon system.
- </dd><dt><span class="term">forceupdate</span></dt><dd>
- Force an update of the desktop icon system. This is only useful if
- the last call to xdg-icon included the <code class="option">--noupdate</code> option.
- </dd></dl></div></div><div class="refsect1" lang="en"><a name="options"></a><h2>Options</h2><div class="variablelist"><dl><dt><span class="term"><code class="option">--noupdate</code></span></dt><dd>
- Postpone updating the desktop icon system. If multiple icons are
- added in sequence this flag can be used to indicate that
- additional changes will follow and that it is not
- necassery to update the desktop icon system right away.
- </dd><dt><span class="term"><code class="option">--theme</code> <em class="replaceable"><code>theme</code></em></span></dt><dd>
- Installs or removes the icon file as part of
- <em class="replaceable"><code>theme</code></em>. If no theme is specified the
- icons will be installed as part of the default <span class="emphasis"><em>hicolor</em></span> theme.
- Applications may install icons under multiple themes but should
- at least install icons for the default <span class="emphasis"><em>hicolor</em></span> theme.
- </dd><dt><span class="term"><code class="option">--context</code> <em class="replaceable"><code>context</code></em></span></dt><dd>
- Specifies the context for the icon. Icons to be used in the
- application menu and as desktop icon should use
- <span class="emphasis"><em>apps</em></span> as context which is the default
- context. Icons to be used as file icons should use
- <span class="emphasis"><em>mimetypes</em></span> as context.
- Other common contexts are <span class="emphasis"><em>actions</em></span>,
- <span class="emphasis"><em>devices</em></span>, <span class="emphasis"><em>emblems</em></span>,
- <span class="emphasis"><em>filesystems</em></span> and <span class="emphasis"><em>stock</em></span>.
- </dd><dt><span class="term"><code class="option">--size</code> <em class="replaceable"><code>size</code></em></span></dt><dd>
- Specifies the size of the icon (required for png and xpm icons).
- All icons must be square.
- Common sizes for icons in the apps context are:
- 16, 22, 32, 48, 64 and 128.
- Common sizes for icons in the mimetypes context are:
- 16, 22, 32, 48, 64 and 128
- </dd><dt><span class="term"><code class="option">--user</code></span></dt><dd>
- Installs or uninstalls the icon for the current user only.
- </dd><dt><span class="term"><code class="option">--system</code></span></dt><dd>
- Installs or uninstalls the icon for all users on the system.
- Usually only root is allowed to do this.
- </dd><dt><span class="term"><code class="option">--help</code></span></dt><dd>
- Show command synopsis.
- </dd><dt><span class="term"><code class="option">--manual</code></span></dt><dd>
- Show this manualpage.
- </dd><dt><span class="term"><code class="option">--version</code></span></dt><dd>
- Show the xdg-utils version information.
- </dd></dl></div></div><div class="refsect1" lang="en"><a name="exitcodes"></a><h2>Exit Codes</h2><p>
- An exit code of 0 indicates success while a non-zero exit code
- indicates failure. The following failure codes can be returned:
- </p><div class="variablelist"><dl><dt><span class="term"><code class="option">1</code></span></dt><dd>
- Error in command line syntax.
- </dd><dt><span class="term"><code class="option">2</code></span></dt><dd>
- One of the files passed on the command line did not exist.
- </dd><dt><span class="term"><code class="option">3</code></span></dt><dd>
- A required tool could not be found.
- </dd><dt><span class="term"><code class="option">4</code></span></dt><dd>
- The action failed.
- </dd></dl></div></div><div class="refsect1" lang="en"><a name="seealso"></a><h2>See Also</h2><p><span class="citerefentry"><span class="refentrytitle">xdg-desktop</span>(1)</span>,
- <span class="citerefentry"><span class="refentrytitle">xdg-menu</span>(1)</span>,
- <span class="citerefentry"><span class="refentrytitle">xdg-mime</span>(1)</span>
- </p></div><div class="refsect1" lang="en"><a name="examples"></a><h2>Examples</h2><p>
- TBD
- </p></div></div></body></html>
diff --git a/scripts/html/xdg-menu.html b/scripts/html/xdg-menu.html
deleted file mode 100644
index a7e0772..0000000
--- a/scripts/html/xdg-menu.html
+++ /dev/null
@@ -1,259 +0,0 @@
-<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>xdg-menu</title><meta name="generator" content="DocBook XSL Stylesheets V1.68.1"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en"><a name="xdg-menu"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>xdg-menu &#8212; command line tool for (un)installing desktop menu items</p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><div class="cmdsynopsis"><p><code class="command">xdg-menu</code> install [<code class="option">--noupdate</code>] [<code class="option">--vendor <em class="replaceable"><code>vendor-id</code></em></code>] { <code class="option">--user</code> | <code class="option">--system</code> } { <em class="replaceable"><code>desktop-file</code></em> | <em class="replaceable"><code>menu-file</code></em> | <em class="replaceable"><code>directory-file</code></em> }</p></div><div class="cmdsynopsis"><p><code class="command">xdg-menu</code> uninstall [<code class="option">--noupdate</code>] [<code class="option">--vendor <em class="replaceable"><code>vendor-id</code></em></code>] { <code class="option">--user</code> | <code class="option">--system</code> } { <em class="replaceable"><code>desktop-file</code></em> | <em class="replaceable"><code>menu-file</code></em> | <em class="replaceable"><code>directory-file</code></em> }</p></div><div class="cmdsynopsis"><p><code class="command">xdg-menu</code> forceupdate { <code class="option">--user</code> | <code class="option">--system</code> }</p></div><div class="cmdsynopsis"><p><code class="command">xdg-menu</code> { <code class="option">--help</code> | <code class="option">--manual</code> | <code class="option">--version</code> }</p></div></div><div class="refsect1" lang="en"><a name="description"></a><h2>Description</h2><p>
- The xdg-menu program can be used to install new items to the
- desktop's application menu.
- </p><p>
- The application menu works according to the
- XDG Desktop Menu Specification at
- http://www.freedesktop.org/Standards/menu-spec
- </p></div><div class="refsect1" lang="en"><a name="commands"></a><h2>Commands</h2><div class="variablelist"><dl><dt><span class="term">install</span></dt><dd><p>
- Install applications or submenus into the desktop menu system.
- </p><p><em class="replaceable"><code>desktop-file</code></em>:
- Installs the *.desktop file indicated by <em class="replaceable"><code>desktop-file</code></em>
- to the menu system. A desktop file represents a single application in the menu.
- Desktop files are defined by the freedesktop.org Desktop Entry
- Specification. The most important aspects of *.desktop
- files are summarized below.
- </p><p><em class="replaceable"><code>menu-file</code></em>:
- Installs the *.menu file indicated by <em class="replaceable"><code>menu-file</code></em>
- to the menu system. A menu file describes the location and contents for
- one or more new submenus. Each submenu must reference a *.directory file.
- </p><p><em class="replaceable"><code>directory-file</code></em>:
- Installs the *.directory file indicated by <em class="replaceable"><code>directory-file</code></em>
- to the menu system. A directory file provides the name and icon for a submenu.
- </p></dd><dt><span class="term">uninstall</span></dt><dd>
- Remove applications or submenus from the desktop menu system
- previously installed with <span><strong class="command">xdg-menu install</strong></span>.
- </dd><dt><span class="term">forceupdate</span></dt><dd>
- Force an update of the menu system. This is only useful if
- the last call to xdg-menu included the <code class="option">--noupdate</code> option.
- </dd></dl></div></div><div class="refsect1" lang="en"><a name="options"></a><h2>Options</h2><div class="variablelist"><dl><dt><span class="term"><code class="option">--noupdate</code></span></dt><dd>
- Postpone updating the menu system. If multiple updates to the
- menu system are made in sequence this flag can be used to
- indicate that additional changes will follow and that it is not
- necassery to update the menu system right away.
- </dd><dt><span class="term"> <code class="option">--vendor</code> <em class="replaceable"><code>vendor-id</code></em></span></dt><dd>
- Adds <em class="replaceable"><code>vendor-id</code></em> as a prefix when installing desktop
- and directory files.
- </dd><dt><span class="term"><code class="option">--user</code></span></dt><dd>
- Installs or uninstalls the file for the current user only.
- </dd><dt><span class="term"><code class="option">--system</code></span></dt><dd>
- Installs or uninstalls the file for all users on the system.
- Usually only root is allowed to do this.
- </dd><dt><span class="term"><code class="option">--help</code></span></dt><dd>
- Show command synopsis.
- </dd><dt><span class="term"><code class="option">--manual</code></span></dt><dd>
- Show this manualpage.
- </dd><dt><span class="term"><code class="option">--version</code></span></dt><dd>
- Show the xdg-utils version information.
- </dd></dl></div></div><div class="refsect1" lang="en"><a name="desktopfiles"></a><h2>Desktop Files</h2><p>
- An application item in the application menu is represented by a
- *.desktop file. A *.desktop file consists of a
- <span class="emphasis"><em>[Desktop Entry]</em></span> header followed by several
- <em class="replaceable"><code>Key</code></em>=<em class="replaceable"><code>Value</code></em> lines.
- </p><p>
- A *.desktop file can provide a name and description for an application
- in several different languages. This is done by adding a language
- code as used by LC_MESSAGES in square brackets behind the
- <em class="replaceable"><code>Key</code></em>. This way one can specify different
- values for the same <em class="replaceable"><code>Key</code></em> depending on the
- currently selected language.
- </p><p>
- The following keys are often used:
- </p><div class="variablelist"><dl><dt><span class="term">Value=1.0</span></dt><dd>
- This is a mandatory field to indicate that the *.desktop file
- follows the 1.0 version of the specification.
- </dd><dt><span class="term">Type=Application</span></dt><dd>
- This is a mandatory field that indicates that the *.desktop file
- describes an application launcher.
- </dd><dt><span class="term">Name=<em class="replaceable"><code>Application Name</code></em></span></dt><dd>
- The name of the application.
- For example <span class="emphasis"><em>Mozilla</em></span>
- </dd><dt><span class="term">GenericName=<em class="replaceable"><code>Generic Name</code></em></span></dt><dd>
- A generic description of the application.
- For example <span class="emphasis"><em>Web Browser</em></span>
- </dd><dt><span class="term">Comment=<em class="replaceable"><code>Comment</code></em></span></dt><dd>
- Optional field to specify a tooltip for the application.
- For example <span class="emphasis"><em>Visit websites on the Internet</em></span>
- </dd><dt><span class="term">Icon=<em class="replaceable"><code>Icon File</code></em></span></dt><dd>
- The icon to use for the application. This can either be
- an absolute path to an image file or an icon-name.
- If an icon-name is provided an image lookup by name is done
- in the user's current icon theme. The <span><strong class="command">xdg-icon</strong></span>
- command can be used to install image files into icon themes.
- The advantage of using an icon-name instead of an absolute
- path is that with an icon-name the application icon can be
- provided in several different sizes as well as in several
- differently themed styles.
- </dd><dt><span class="term">Exec=<em class="replaceable"><code>Command Line</code></em></span></dt><dd>
- The command line to start the application. If the application
- can open files the %f placeholder should be specified. When
- a file is dropped on the application launcher the %f is replaced
- with the file path of the dropped file. If multiple files
- can be specified on the command line the %F placeholder should
- be used instead of %f. If the application is able to open URLs
- in addition to local files then %u or %U can be used instead
- of %f or %F.
- </dd><dt><span class="term">Categories=<em class="replaceable"><code>Categories</code></em></span></dt><dd>
- A list of categories separated by semi-colons. A category is
- a keyword that describes and classifies the application.
- By default applications are organized in the application menu
- based on category. The XDG Desktop Menu Specification defines
- a large number of predefined categories.
- </dd><dt><span class="term">MimeType=<em class="replaceable"><code>Mimetypes</code></em></span></dt><dd>
- A list of mimetypes separated by semi-colons. This field is
- used to indicate which file types the application is able to
- open.
- </dd></dl></div><p>
- For a complete oveview of the *.desktop file format please
- visit http://www.freedesktop.org/wiki/Standards/desktop-entry-spec
- </p></div><div class="refsect1" lang="en"><a name="exitcodes"></a><h2>Exit Codes</h2><p>
- An exit code of 0 indicates success while a non-zero exit code
- indicates failure. The following failure codes can be returned:
- </p><div class="variablelist"><dl><dt><span class="term"><code class="option">1</code></span></dt><dd>
- Error in command line syntax.
- </dd><dt><span class="term"><code class="option">2</code></span></dt><dd>
- One of the files passed on the command line did not exist.
- </dd><dt><span class="term"><code class="option">3</code></span></dt><dd>
- A required tool could not be found.
- </dd><dt><span class="term"><code class="option">4</code></span></dt><dd>
- The action failed.
- </dd></dl></div></div><div class="refsect1" lang="en"><a name="seealso"></a><h2>See Also</h2><p><span class="citerefentry"><span class="refentrytitle">xdg-desktop</span>(1)</span>,
- <span class="citerefentry"><span class="refentrytitle">xdg-icon</span>(1)</span>,
- <span class="citerefentry"><span class="refentrytitle">xdg-mime</span>(1)</span>
- </p></div><div class="refsect1" lang="en"><a name="examples"></a><h2>Examples</h2><p>
- The company ShinyThings Inc. has developed an application named
- "WebMirror" and would like to add it to the application menu.
- The company will use "shinythings" as its vendor id.
- In order to add the application to the menu there needs to be a
- .desktop file with a suitable <span class="emphasis"><em>Categories</em></span> entry:
-</p><pre class="programlisting">
-webmirror.desktop:
-
- [Desktop Entry]
- Encoding=UTF-8
- Type=Application
-
- Exec=webmirror
- Icon=webmirror
-
- Name=WebMirror
- Name[nl]=WebSpiegel
-
- Categories=Network;WebDevelopment;
-</pre><p>
- </p><p>Now the xdg-menu tool can be used to add the webmirror.desktop file
- to the desktop application menu:
-</p><pre class="programlisting">
-xdg-menu install --system --vendor shinythings ./webmirror.desktop
-</pre><p>
- </p><p>
- Note that for the purpose of this example the menu items are available
- in two languages, English and Dutch.
- The language code for Dutch is nl.
- </p><p>
- In the next example the company ShinyThings Inc. wants to add its own
- submenu to the desktop application menu consisting of a
- "WebMirror" menu item and a
- "WebMirror Admin Tool" menu item.
- </p><p>
- First the company needs to create two .desktop files that describe
- the two menu items, this time no Categories item is needed:
-</p><pre class="programlisting">
-webmirror.desktop:
-
- [Desktop Entry]
- Encoding=UTF-8
- Type=Application
-
- Exec=webmirror
- Icon=webmirror
-
- Name=WebMirror
- Name[nl]=WebSpiegel
-
-
-webmirror-admin.desktop:
-
- [Desktop Entry]
- Encoding=UTF-8
- Type=Application
-
- Exec=webmirror-admintool
- Icon=webmirror-admintool
-
- Name=WebMirror Admin Tool
- Name[nl]=WebSpiegel Administratie Tool
-</pre><p>
- </p><p>
- The files can be installed with:
-</p><pre class="programlisting">
-xdg-menu install --system --noupdate --vendor shinythings ./webmirror.desktop
-xdg-menu install --system --noupdate --vendor shinythings ./webmirror-admin.desktop
-</pre><p>
- </p><p>
- Because multiple items are added the <code class="option">--noupdate</code>
- option has been used.
- </p><p>
- In addition a .directory file needs to be created to provide a title and icon
- for the sub-menu itself:
-</p><pre class="programlisting">
-webmirror.directory:
-
- [Desktop Entry]
- Encoding=UTF-8
-
- Icon=webmirror-menu
-
- Name=WebMirror
- Name[nl]=WebSpiegel
-</pre><p>
- </p><p>
- This webmirror.directory file can be installed with:
-</p><pre class="programlisting">
-xdg-menu install --system --noupdate --vendor shinythings ./webmirror.directory
-</pre><p>
- </p><p>
- The *.desktop and *.directory files reference icons with the names
- webmirror, webmirror-admin and webmirror-menu which should also be
- installed. In this example the icons are installed in two different
- sizes, once with a size of 22x22 pixels and once with a size
- of 64x64 pixels:
-</p><pre class="programlisting">
-xdg-icon install --system --size 22 ./wmicon-22.png webmirror.png
-xdg-icon install --system --size 22 ./wmicon-menu-22.png webmirror-menu.png
-xdg-icon install --system --size 22 ./wmicon-admin-22.png webmirror-admin.png
-xdg-icon install --system --size 64 ./wmicon-64.png webmirror.png
-xdg-icon install --system --size 64 ./wmicon-menu-64.png webmirror-menu.png
-xdg-icon install --system --size 64 ./wmicon-admin-64.png webmirror-admin.png
-</pre><p>
- </p><p>
- The last step is to provide a .menu file that links it all
- togther:
-</p><pre class="programlisting">
-webmirror.menu:
-
- &lt;!DOCTYPE Menu PUBLIC "-//freedesktop//DTD Menu 0.8//EN"
- "http://www.freedesktop.org/standards/menu-spec/menu-0.8.dtd"&gt;
- &lt;Menu&gt;
- &lt;Menu&gt;
- &lt;Name&gt;WebMirror&lt;/Name&gt;
- &lt;Directory&gt;shinythings-webmirror.directory&lt;/Directory&gt;
- &lt;Include&gt;
- &lt;Filename&gt;shinythings-webmirror.desktop&lt;/Filename&gt;
- &lt;Filename&gt;shinythings-webmirror-admin.desktop&lt;/Filename&gt;
- &lt;/Include&gt;
- &lt;/Menu&gt;
- &lt;/Menu&gt;
-</pre><p>
- </p><p>
- The webmirror.menu file can be installed with:
-</p><pre class="programlisting">
-xdg-menu install --system --noupdate --vendor shinythings ./webmirror.menu
-</pre><p>
- </p><p>
- After installing multiple files with <code class="option">--noupdate</code> make sure
- to force an update:
-</p><pre class="programlisting">
-xdg-menu forceupdate --system
-</pre><p>
- </p></div></div></body></html>