1ROFI-DMENU(5) File Formats Manual ROFI-DMENU(5)
2
3
4
6 rofi dmenu mode - Rofi dmenu emulation
7
8
10 To integrate rofi into scripts as simple selection dialogs, rofi sup‐
11 ports emulating dmenu(1) (A dynamic menu for X11).
12
13
14 The website for dmenu can be found here ⟨http://tools.suck‐
15 less.org/dmenu/⟩.
16
17
18 rofi does not aim to be 100% compatible with dmenu. There are simply
19 too many flavors of dmenu. The idea is that the basic usage com‐
20 mand-line flags are obeyed, theme-related flags are not. Besides, rofi
21 offers some extended features (like multi-select, highlighting, message
22 bar, extra key bindings).
23
24
26 In dmenu mode, rofi reads data from standard in, splits them into sepa‐
27 rate entries and displays them. If the user selects an row, this is
28 printed out to standard out, allow the script to process it further.
29
30
31 By default separation of rows is done on new lines, making it easy to
32 pipe the output a one application into rofi and the output of rofi into
33 the next.
34
35
37 By launching rofi with the -dmenu flag it will go into dmenu emulation
38 mode.
39
40
41 ls | rofi -dmenu
42
43
44
45 DMENU DROP-IN REPLACEMENT
46 If argv[0] (calling command) is dmenu, rofi will start in dmenu mode.
47 This way, it can be used as a drop-in replacement for dmenu. Just copy
48 or symlink rofi to dmenu in $PATH.
49
50
51 ln -s /usr/bin/rofi /usr/bin/dmenu
52
53
54
55 DMENU VS SCRIPT MODE
56 Script mode is used to extend rofi, dmenu mode is used to extend a
57 script. The two do share much of the same input format. Please see the
58 rofi-script(5) manpage for more information.
59
60
61 DMENU SPECIFIC COMMANDLINE FLAGS
62 A lot of these options can also be modified by the script using special
63 input. See the rofi-script(5) manpage for more information about this
64 syntax.
65
66
67 -sep separator
68
69
70 Separator for dmenu. Example: To show a list of 'a' to 'e' with '|' as
71 a separator:
72
73
74 echo "a|b|c|d|e" | rofi -sep '|' -dmenu
75
76
77
78 -p prompt
79
80
81 Specify the prompt to show in dmenu mode. For example, select 'monkey',
82 a,b,c,d, or e.
83
84
85 echo "a|b|c|d|e" | rofi -sep '|' -dmenu -p "monkey"
86
87
88
89 Default: dmenu
90
91
92 -l number of lines to show
93
94
95 Maximum number of lines the menu may show before scrolling.
96
97
98 rofi -dmenu -l 25
99
100
101
102 Default: 15
103
104
105 -i
106
107
108 Makes dmenu searches case-insensitive
109
110
111 -a X
112
113
114 Active row, mark X as active. Where X is a comma-separated list of
115 python(1)-style indices and ranges, e.g. indices start at 0, -1 refers
116 to the last row with -2 preceding it, ranges are left-open and
117 right-close, and so on. You can specify:
118
119
120 • A single row: '5'
121
122 • A range of (last 3) rows: '-3:'
123
124 • 4 rows starting from row 7: '7:11' (or in legacy notation:
125 '7-10')
126
127 • A set of rows: '2,0,-9'
128
129 • Or any combination: '5,-3:,7:11,2,0,-9'
130
131
132
133 -u X
134
135
136 Urgent row, mark X as urgent. See -a option for details.
137
138
139 -only-match
140
141
142 Only return a selected item, do not allow custom entry. This mode al‐
143 ways returns an entry. It will not return if no matching entry is se‐
144 lected.
145
146
147 -no-custom
148
149
150 Only return a selected item, do not allow custom entry. This mode re‐
151 turns directly when no entries given.
152
153
154 -format format
155
156
157 Allows the output of dmenu to be customized (N is the total number of
158 input entries):
159
160
161 • 's' selected string
162
163 • 'i' index (0 - (N-1))
164
165 • 'd' index (1 - N)
166
167 • 'q' quote string
168
169 • 'p' Selected string stripped from Pango markup (Needs to be a
170 valid string)
171
172 • 'f' filter string (user input)
173
174 • 'F' quoted filter string (user input)
175
176
177
178 Default: 's'
179
180
181 -select string
182
183
184 Select first line that matches the given string
185
186
187 -mesg string
188
189
190 Add a message line below the filter entry box. Supports Pango markup.
191 For more information on supported markup, see here
192 ⟨https://docs.gtk.org/Pango/pango_markup.html⟩
193
194
195 -dump
196
197
198 Dump the filtered list to stdout and quit. This can be used to get the
199 list as rofi would filter it. Use together with -filter command.
200
201
202 -input file
203
204
205 Reads from file instead of stdin.
206
207
208 -password
209
210
211 Hide the input text. This should not be considered secure!
212
213
214 -markup-rows
215
216
217 Tell rofi that DMenu input is Pango markup encoded, and should be ren‐
218 dered. See here ⟨https://developer.gnome.org/pygtk/stable/pango-
219 markup-language.html⟩ for details about Pango markup.
220
221
222 -multi-select
223
224
225 Allow multiple lines to be selected. Adds a small selection indicator
226 to the left of each entry.
227
228
229 -sync
230
231
232 Force rofi mode to first read all data from stdin before showing the
233 selection window. This is original dmenu behavior.
234
235
236 Note: the default asynchronous mode will also be automatically disabled
237 if used with conflicting options, such as -dump, -only-match or
238 -auto-select.
239
240
241 -async-pre-read number
242
243
244 Reads the first number entries blocking, then switches to async mode.
245 This makes it feel more 'snappy'.
246
247
248 default: 25
249
250
251 -window-title title
252
253
254 Set name used for the window title. Will be shown as Rofi - title
255
256
257 -w windowid
258
259
260 Position rofi over the window with the given X11 window ID.
261
262
263 -keep-right
264
265
266 Set ellipsize mode to start. So, the end of the string is visible.
267
268
270 • 0: Row has been selected accepted by user.
271
272 • 1: User cancelled the selection.
273
274 • 10-28: Row accepted by custom keybinding.
275
276
277
279 rofi(1), rofi-sensible-terminal(1), dmenu(1), rofi-theme(5),
280 rofi-script(5), rofi-theme-selector(1)
281
282
284 Qball Cow ⟨qball@gmpclient.org⟩
285
286
287 Rasmus Steinke ⟨rasi@xssn.at⟩
288
289
290 Quentin Glidic ⟨sardemff7+rofi@sardemff7.net⟩
291
292
293 Original code based on work by: Sean Pringle ⟨sean.pringle@gmail.com⟩
294
295
296 For a full list of authors, check the AUTHORS file.
297
298
299
300 rofi-dmenu ROFI-DMENU(5)