571d99e1 |
1 | XMenu |
a7732690 |
2 | |
571d99e1 |
3 | XMenu is a menu utility for X. |
4 | XMenu receives a menu specification in stdin, shows a menu for the user |
a7732690 |
5 | to select one of the options, and outputs the option selected to stdout. |
571d99e1 |
6 | XMenu can be controlled both via mouse and via keyboard. The menu is a |
7 | pop-up menu (that is, after selecting an option, the menu disappears). |
8 | |
9 | NOTE: |
10 | The -w (windowed) option was removed from the master branch. It was too |
11 | buggy in tiled window managers and required more code to be maintained. |
12 | |
13 | |
33376f54 |
14 | § Features |
15 | |
16 | XMenu comes with the following features: |
17 | • XMenu reads something in and prints something out, the UNIX way. |
18 | • Submenus (some menu entries can spawn another menu). |
19 | • Separators (menu entries can be separated by a line). |
20 | • Icons (menu entries can follow by an icon image). |
21 | |
22 | |
571d99e1 |
23 | § Files |
24 | |
25 | The files are: |
26 | • ./README: This file. |
27 | • ./Makefile: The makefile. |
28 | • ./config.h: The hardcoded default configuration for XMenu. |
29 | • ./config.mk: The setup for the makefile. |
ddeb6e1e |
30 | • ./demo.gif: A gif demonstrating how XMenu works. |
571d99e1 |
31 | • ./xmenu.1: The manual file (man page) for XMenu. |
32 | • ./xmenu.c: The source code of XMenu. |
33 | • ./xmenu.sh: A sample script illustrating how to use XMenu. |
33376f54 |
34 | • ./icons/: Icons for the sample script |
a7732690 |
35 | |
27443900 |
36 | |
a7732690 |
37 | § Installation |
38 | |
571d99e1 |
39 | First, edit ./config.mk to match your local setup. |
40 | |
33376f54 |
41 | In order to build XMenu you need the Imlib2, Xlib and Xft header files. |
571d99e1 |
42 | The default configuration for XMenu is specified in the file config.h, |
43 | you can edit it, but most configuration can be changed at runtime via |
44 | X resources. Enter the following command to build XMenu. This command |
45 | creates the binary file ./xmenu. |
a7732690 |
46 | |
571d99e1 |
47 | make |
a7732690 |
48 | |
571d99e1 |
49 | By default, XMenu is installed into the /usr/local prefix. Enter the |
50 | following command to install XMenu (if necessary as root). This command |
51 | installs the binary file ./xmenu into the ${PREFIX}/bin/ directory, and |
52 | the manual file ./xmenu.1 into ${MANPREFIX}/man1/ directory. |
a7732690 |
53 | |
571d99e1 |
54 | make install |
a7732690 |
55 | |
a7732690 |
56 | |
571d99e1 |
57 | § Running XMenu |
58 | |
59 | XMenu receives as input a menu specification where each line is a menu |
a7732690 |
60 | entry. Each line can be indented with tabs to represent nested menus. |
61 | Each line is made out of a label and a command separated by any number |
7fbd1c5e |
62 | of tabs. Lines without labels are menu separators. |
a7732690 |
63 | |
4f898cc3 |
64 | See the script ./xmenu.sh for an example of how to use XMenu to draw a |
65 | simple menu with submenus and separators. The file ./demo.gif shows how |
66 | the menu generated by that script looks like. |
571d99e1 |
67 | |
68 | Read the manual for more information on running XMenu. |
69 | |
70 | |
71 | § License |
08f16589 |
72 | |
571d99e1 |
73 | This software is in public domain and is provided AS IS, with NO WARRANTY. |