08f16589 |
1 | .TH PROG 1 |
2 | .SH NAME |
3 | xmenu \- menu utility for X |
4 | .SH SYNOPSIS |
5 | .B xmenu |
6 | .RB [ \-w ] |
c0cff00d |
7 | .RI [ title... ] |
08f16589 |
8 | .SH DESCRIPTION |
9 | .B xmenu |
10 | is a menu for X, |
11 | it reads a list of newline-separated items from stdin, |
12 | shows a menu for the user to select one of the items, |
13 | and outputs the item selected to stdout. |
14 | .PP |
15 | The options are as follows: |
16 | .TP |
17 | .B -w |
18 | Asks the window manager to draw a border around the menus. |
19 | Without this options, the menus do not have border drawn by the window manager. |
20 | .PP |
21 | Each item read from stdin has the following format: |
22 | .IP |
23 | .EX |
24 | ITEM := TABS LABEL TABS COMMAND NEWLINE |
25 | .EE |
26 | .PP |
27 | That means, each item is composed by |
28 | tabs, followed by a label, followed by more tabs, followed by a command, |
29 | and ended by a newline. |
30 | .IP |
31 | The initial tabs indicate the menu hierarchy: |
32 | items indented with a tab is shown in a submenu of the preceding item not indented. |
33 | .IP |
34 | The label is the string that will be shown as a item in the menu. |
35 | An item without label is considered a separator and is drawn as a thin line in the menu |
36 | separating the item above from the item below. |
37 | .IP |
38 | The command is the string that will be output after selecting the item. |
c0cff00d |
39 | If the item spawns a submenu, the command is the title of the menu. |
08f16589 |
40 | .IP |
41 | The newline terminates the item specification. |
c0cff00d |
42 | .PP |
43 | If the argument |
44 | .I title |
45 | is given, the title of the menu window is set to it. |
858338d9 |
46 | .SH USAGE |
47 | .B xmenu |
48 | is controlled by the mouse, |
49 | but can also be controlled by the keyboard. |
50 | Items can be selected using the arrow keys, |
51 | Tab (with and without Shift), |
52 | Enter and Esc. |
53 | .TP |
54 | .BR Down ", " Tab |
55 | Cycle through the items in the regular direction. |
56 | .TP |
57 | .BR Up ", " Shift-Tab |
58 | Cycle through the items in the reverse direction. |
59 | .TP |
60 | .BR Right ", " Enter |
61 | Select the highlighted item. |
62 | .TP |
63 | .B Left |
64 | Go to the menu above. |
65 | .TP |
66 | .B Esc |
67 | Go to the menu above or exit xmenu. |
f644b8bc |
68 | .SH RESOURCES |
69 | .B |
70 | xmenu |
71 | understands the following X resources. |
72 | .TP |
73 | .B xmenu.font |
74 | The font in which the labels should be drawn. |
75 | .TP |
76 | .B xmenu.background |
77 | The background color of non-selected itens in the menu. |
78 | .TP |
79 | .B xmenu.foreground |
80 | The color of the label text of non-selected itens in the menu. |
81 | .TP |
82 | .B xmenu.selbackground |
83 | The background color of selected itens in the menu. |
84 | .TP |
85 | .B xmenu.selforeground |
86 | The color of the label text of selected itens in the menu. |
87 | .TP |
88 | .B xmenu.border |
89 | The color of the border around the menu. |
90 | .TP |
91 | .B xmenu.separator |
92 | The color of the separator between itens in the menu. |
93 | .TP |
94 | .B xmenu.width |
95 | The minimum width, in pixels, of the items in the menu. |
96 | .TP |
97 | .B xmenu.itemborder |
98 | The size in pixels of the border around the label text in items in the menu. |
99 | .TP |
100 | .B xmenu.menuborder |
101 | The size in pixels of the border around the menu. |
102 | .TP |
103 | .B xmenu.separatorsize |
104 | The size in pixels of the item separator. |
105 | |
08f16589 |
106 | .SH EXAMPLES |
c49dad28 |
107 | The following is an script exemplifying the use of |
08f16589 |
108 | .BR xmenu . |
c49dad28 |
109 | The output is redirected to |
110 | .IR sh (1), |
111 | creating a command to be run by the shell. |
08f16589 |
112 | .IP |
113 | .EX |
114 | #!/bin/sh |
115 | |
c49dad28 |
116 | cat <<EOF | xmenu | sh |
08f16589 |
117 | Applications |
118 | Web Browser firefox |
119 | Image editor gimp |
120 | Terminal (xterm) xterm |
121 | Terminal (urxvt) urxvt |
122 | Terminal (st) st |
123 | |
124 | Shutdown poweroff |
125 | Reboot reboot |
126 | EOF |
127 | .EE |
128 | .PP |
129 | For example, by selecting \(lqApplications\(rq, a new menu will appear. |
130 | Selecting \(lqWeb Browser\(rq in the new menu will open firefox. |
131 | .SH SEE ALSO |
132 | .IR dmenu (1), |
133 | .IR 9menu (1), |
134 | .IR thingmenu (1) |