Blob


1 MYMENU(1) - General Commands Manual
3 # NAME
5 **mymenu** - simple menu for XOrg
7 # DESCRIPTION
9 The
10 **mymenu**
11 utility a simple graphical menu for XOrg. It read the items from
12 **stdin**
13 and print the user selection to
14 **stdout**
15 on exit.
17 # OPTIONS
19 **-a**
21 > The first completion (if any) is always selected. This is like dmenu.
23 **-h**
25 > Print a small usage message to stderr.
27 **-v**
29 > Print version and exit.
31 # RESOURCES
33 The appearance of the menu is defined through the **X Resource**
34 Database.
36 MyMenu.font
38 > The font name to use. By default is set to "fixed" if compiled without
39 > Xft(3) support, "monospace" otherwise. Without Xft(3) only bitmap font
40 > are supported.
42 MyMenu.layout
44 > The layout of the menu. The possible values are "horizontal" and
45 > "vertical", with the default being "horizontal". Every other value
46 > than "horizontal" is treated like "vertical", but this is kinda an
47 > implementation detail and not something to be relied on, since in the
48 > future other layout could be added as well.
50 Mymenu.prompt
52 > A string that is rendered before the user input. Default to "$ ".
54 MyMenu.width
56 > The width of the menu. If a numeric value is given (e.g. 400) is
57 > interpreted as pixel, if it ends with a percentage symbol \`%'
58 > (e.g. 40%) the relative percentage will be computed (relative to the
59 > monitor width).
61 MyMenu.height
63 > The height of the menu. Like MyMenu.width if a numeric value is given
64 > is interpreted as pixel, if it ends with a percentage symbol \`%' the
65 > relative percentage will be computed (relative to the monitor height).
67 MyMenu.x
69 > The X coordinate of the topmost left corner of the window. Much like
70 > MyMenu.height and MyMenu.width both a pixel dimension and percentage
71 > could be supplied. In addition to it, the special value "middle" could
72 > be used: in that case the window will be centered on the x axes.
74 MyMenu.y
76 > The Y coordinate of the topmost left corner of the window. Like the X
77 > coordinate a pixel dimension, percentage dimension or the special
78 > value "middle" could be supplied.
80 MyMenu.padding
82 > Change the padding. In the horizontal layout the padding is the space
83 > between the rectangle of the completion and the text as well as the
84 > space between the prompt and the first completion. In the horizontal
85 > layout the padding is the horizontal spacing between the window edge
86 > and the text as well as the space up and down the text within the
87 > completion. The default value is 10.
89 MyMenu.prompt.background
91 > The background of the prompt.
93 MyMenu.prompt.foreground
95 > The text color (foreground) of the prompt.
97 MyMenu.completion.background
99 > The background of the completions.
101 MyMenu.completion.foreground
103 > The text color of the completions.
105 MyMenu.completion\_highlighted.background
107 > The background of the selected completion.
109 MyMenu.completion\_highlighted.foreground
111 > The foreground of the selected completion.
113 # KEYS
115 This is the list of keybinding recognized by
116 **mymenu**.
117 In the following examples, C-c means Control-c.
119 Esc
121 > Close the menu without selecting any entry
123 C-c
125 > The same as Esc
127 Enter
129 > Close the menu and print to stdout what the user typed
131 C-m
133 > The same as Enter
135 Tab
137 > Expand the prompt to the next possible completion
139 Shift Tab
141 > Expand the prompt to the previous possible completion
143 C-n
145 > The same as Tab
147 C-p
149 > The same as Shift-Tab
151 Backspace
153 > Delete the last character
155 C-h
157 > The same as Backspace
159 C-w
161 > Delete the last word
163 C-u
165 > Delete the whole line
167 # BUGS
169 * If, instead of a numeric value, a not-valid number that terminates
170 with the % sign is supplied, then the default value for that field
171 will be treated as a percentage. Since this is a misuse of the
172 resources this behavior isn't strictly considered a bug.
174 * C-w (delete last word) does not work well with multi-byte string. The
175 whole UTF-8 support is still kinda naïve and should be improved.
177 # EXIT STATUS
179 0 when the user select an entry, 1 when the user press Esc, EX\_USAGE
180 if used with wrong flags and EX\_UNAVAILABLE if the connection to X
181 fails.
183 # SEE ALSO
185 dmenu(1)
186 sysexits(3)
188 # AUTHORS
190 Omar Polo <omar.polo@europecom.net>
192 OpenBSD 6.3 - July 1, 2018