xdgmenumaker
George Vlahavas
%%mtime(%m/%d/%Y)
%!target: man
%!encoding: utf-8
= NAME =
xdgmenumaker - generate XDG menus
= SYNOPSIS =
**xdgmenumaker** [//OPTIONS//]
= DESCRIPTION =
**xdgmenumaker** is a command line tool, written in python, that
generates application menus using XDG information, by scanning
*.desktop files in all //$XDG_DATA_DIRS/applications// directories. All
applications are sorted according to the main categories as specified
by
[freedesktop.org http://standards.freedesktop.org/menu-spec/latest/apa.html]
The menu entries that are generated by **xdgmenumaker** are localised
according to the running user locale settings.
**xdgmenumaker** currently supports generating menus for //blackbox//,
//compizboxmenu//, //fluxbox//, //icewm//, //jwm//, //pekwm// and
//windowmaker//.
pyxdg and pygtk are required by **xdgmenumaker**, in addition to python 2.
= OPTIONS =
: **-f, --format**
specify the output format to use. Valid options are //blackbox//,
//compizboxmenu//, //fluxbox//, //icewm//, //jwm//, //pekwm// and
//windowmaker//.
Specifying the output format is mandatory.
: **-i, --icons**
enable support for icons in the menus. This option does not have any
effect for //blackbox// or //windowmaker// menus.
: **-s, --size**
set the preferred icon size in pixels. The default size is 16. You can
set this to any number, but it generally makes sense to use standard
icons sizes, like 16, 22, 24, 32 etc. Obviously this has an effect only
if the //--icons// option is used. You have to be careful with the sizes
you use; some window managers don't support large icons in the menu.
: **-n, --no-submenu**
do not create a submenu. Instead, place the application categories menus
in the window manager's main menu. This option does not have any effect
for //windowmaker// menus.
: **--pekwm-dynamic**
create dynamic menus for pekwm. If you want to have dynamically
generated menus for pekwm you have to use this option. Do not use it if
you want to generate static menus for pekwm. Only works with //pekwm//
of course.
= GENERAL OPTIONS =
: **-h**
Prints a usage message briefly summarizing all command-line options
and exits.
= CONFIGURATION =
The terminal emulator to be used for menu entries that state that an
application must be launched inside a terminal, can be specified in a
//~/.config/xdgmenumaker.cfg// configuration file. Here's an example
specifying **rxvt** as the default terminal emulator:
```
[Terminal]
terminal = rxvt
```
If no such file is present, or if no terminal is set within the file,
xdgmenumaker will default to the one specified in the debian
alternatives system on debian and debian-like systems and to xterm in
any other case.
Setting the path to a terminal emulator in an //XDGMENUMAKERTERM//
environment variable will override any other setting.
= USAGE =
: **Blackbox**
To generate an application menu for Blackbox, you can run
**xdgmenumaker** like this:
``$ xdgmenumaker -f blackbox > ~/.blackbox/xdg_menu``
and then change your main Blackbox menu to include this file as a
submenu. For example, add this somewhere in your //~/.blackbox/menu// file:
``[include] (~/.blackbox/xdg_menu)``
You can add the **xdgmenumaker** command as another item in your menu,
if you want to update it, without having to run the command manually
again:
``[exec] (Update Blackbox Menu) {xdgmenumaker -f blackbox > ~/.blackbox/xdg_menu}``
: **Compiz Boxmenu**
There are two ways to have an xdg menu in compiz-boxmenu. The first one,
auto-updates the menu, every time the menu is called. The second one,
updates the menu only when the user wants to.
**Dynamic Menus**
Edit your //~/.config/compiz/boxmenu/menu.xml// file with your favorite text
editor and add a block of code like this inside the root //