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 | |
14 | § Files |
15 | |
16 | The files are: |
17 | • ./README: This file. |
18 | • ./Makefile: The makefile. |
19 | • ./config.h: The hardcoded default configuration for XMenu. |
20 | • ./config.mk: The setup for the makefile. |
21 | • ./xmenu.1: The manual file (man page) for XMenu. |
22 | • ./xmenu.c: The source code of XMenu. |
23 | • ./xmenu.sh: A sample script illustrating how to use XMenu. |
a7732690 |
24 | |
27443900 |
25 | |
a7732690 |
26 | § Installation |
27 | |
571d99e1 |
28 | First, edit ./config.mk to match your local setup. |
29 | |
30 | In order to build XMenu you need the Xlib and the Xft header files. |
31 | The default configuration for XMenu is specified in the file config.h, |
32 | you can edit it, but most configuration can be changed at runtime via |
33 | X resources. Enter the following command to build XMenu. This command |
34 | creates the binary file ./xmenu. |
a7732690 |
35 | |
571d99e1 |
36 | make |
a7732690 |
37 | |
571d99e1 |
38 | By default, XMenu is installed into the /usr/local prefix. Enter the |
39 | following command to install XMenu (if necessary as root). This command |
40 | installs the binary file ./xmenu into the ${PREFIX}/bin/ directory, and |
41 | the manual file ./xmenu.1 into ${MANPREFIX}/man1/ directory. |
a7732690 |
42 | |
571d99e1 |
43 | make install |
a7732690 |
44 | |
a7732690 |
45 | |
571d99e1 |
46 | § Running XMenu |
47 | |
48 | XMenu receives as input a menu specification where each line is a menu |
a7732690 |
49 | entry. Each line can be indented with tabs to represent nested menus. |
50 | Each line is made out of a label and a command separated by any number |
7fbd1c5e |
51 | of tabs. Lines without labels are menu separators. |
a7732690 |
52 | |
571d99e1 |
53 | See the script ./xmenu.sh for an example of how XMenu can be used to |
54 | draw a simple menu with submenus and separators. The following gif |
55 | shows how the menu generated by that script looks like. |
56 | |
57 | https://i.redd.it/lxv7jewcwmz41.gif |
58 | |
59 | Read the manual for more information on running XMenu. |
60 | |
61 | |
62 | § License |
08f16589 |
63 | |
571d99e1 |
64 | This software is in public domain and is provided AS IS, with NO WARRANTY. |