Blob


1 .Dd $Mdocdate$
2 .Dt MYMENU 1
3 .Os
4 .Sh NAME
5 .Nm mymenu
6 .Nd simple menu for XOrg
7 .Sh DESCRIPTION
8 The
9 .Nm
10 utility a simple graphical menu for XOrg. It read the items from
11 .Ic stdin
12 and print the user selection to
13 .Ic stdout
14 on exit.
15 .Sh OPTIONS
16 .Bl -tag -width Ds
17 .It Fl a
18 The first completion (if any) is always selected. This is like dmenu
19 .El
20 .Sh RESOURCES
22 The appearance of the menu is defined through the \fBX Resource
23 Database\fR.
24 .Bl -tag -width Ds
25 .It MyMenu.font
26 The font name to use. By default is set to "fixed" if compiled without
27 Xft(3) support, "monospace" otherwise. Without Xft(3) only bitmap font
28 are supported.
29 .It MyMenu.layout
30 The layout of the menu. The possible values are "horizontal" and
31 "vertical", with the default being "horizontal". Every other value
32 than "horizontal" is treated like "vertical", but this is kinda an
33 implementation detail and not something to be relied on, since in the
34 future other layout could be added as well.
35 .It Mymenu.prompt
36 A string that is rendered before the user input. Default to "$ ".
37 .It MyMenu.width
38 The width of the menu. If a numeric value is given (e.g. 400) is
39 interpreted as pixel, if it ends with a percentage symbol `%'
40 (e.g. 40%) the relative percentage will be computed (relative to the
41 monitor width).
42 .It MyMenu.height
43 The height of the menu. Like MyMenu.width if a numeric value is given
44 is interpreted as pixel, if it ends with a percentage symbol `%' the
45 relative percentage will be computed (relative to the monitor height).
46 .It MyMenu.x
47 The X coordinate of the topmost left corner of the window. Much like
48 MyMenu.height and MyMenu.width both a pixel dimension and percentage
49 could be supplied. In addition to it, the special value "middle" could
50 be used: in that case the window will be centered on the x axes.
51 .It MyMenu.y
52 The Y coordinate of the topmost left corner of the window. Like the X
53 coordinate a pixel dimension, percentage dimension or the special
54 value "middle" could be supplied.
55 .It MyMenu.padding
56 Change the padding. In the horizontal layout the padding is the space
57 between the rectangle of the completion and the text as well as the
58 space between the prompt and the first completion. In the horizontal
59 layout the padding is the horizontal spacing between the window edge
60 and the text as well as the space up and down the text within the
61 completion. The default value is 10.
62 .It MyMenu.prompt.background
63 The background of the prompt.
64 .It MyMenu.prompt.foreground
65 The text color (foreground) of the prompt.
66 .It MyMenu.completion.background
67 The background of the completions.
68 .It MyMenu.completion.foreground
69 The text color of the completions.
70 .It MyMenu.completion_highlighted.background
71 The background of the selected completion.
72 .It MyMenu.completion_highlighted.foreground
73 The foreground of the selected completion.
74 .El
76 .Sh KEYS
77 .Bl -tag -width indent-two
78 .It Esc
79 Close the menu without selecting any entry
80 .It Enter
81 Close the menu and print to stdout what the user typed
82 .It C-m
83 The same as Enter
84 .It Tab
85 Expand the prompt to the next possible completion
86 .It Shift Tab
87 Expand the prompt to the previous possible completion
88 .It C-n
89 The same as Tab
90 .It C-p
91 The same as Shift-Tab
92 .It Backspace
93 Delete the last character
94 .It C-h
95 The same as Backspace
96 .It C-w
97 Delete the last word
98 .It C-u
99 Delete the whole line
100 .El
102 .Sh BUGS
103 .Bl -bullet
104 .It
105 If, instead of a numeric value, a not-valid number that terminates
106 with the % sign is supplied, then the default value for that field
107 will be treated as a percentage. Since this is a misuse of the
108 resources this behavior isn't strictly considered a bug.
109 .It
110 C-w (delete last word) does not work well with multi-byte string. The
111 whole UTF-8 support is still kinda naïve and should be improved.
112 .El
114 .Sh EXIT STATUS
116 0 when the user select an entry, 1 when the user press Esc and
117 EX_UNAVAILABLE if the connection to X fails.
119 .Sh SEE ALSO
120 .Xr dmenu 1
121 .Xr sysexits 3
123 .Sh AUTHORS
124 .An Omar Polo <omar.polo@europecom.net>