summaryrefslogtreecommitdiff
path: root/doc/fluxbox-menu.5.in
blob: 64eea3127bbd76f6e65952a5b0aeaf5cba15f879 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
'\" t
.\"     Title: fluxbox-menu
.\"    Author: Jim Ramsay <i.am@jimramsay.com>
.\" Generator: DocBook XSL Stylesheets v1.75.2 <http://docbook.sf.net/>
.\"      Date: 28 October 2011
.\"    Manual: Fluxbox Manual
.\"    Source: fluxbox-menu.txt
.\"  Language: English
.\"
.TH "FLUXBOX\-MENU" "5" "28 October 2011" "fluxbox\-menu\&.txt" "Fluxbox Manual"
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.\" http://bugs.debian.org/507673
.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.ie \n(.g .ds Aq \(aq
.el       .ds Aq '
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.\" -----------------------------------------------------------------
.\" * MAIN CONTENT STARTS HERE *
.\" -----------------------------------------------------------------
.SH "NAME"
fluxbox-menu \- fluxbox(1) menu syntax
.SH "SYNOPSIS"
.sp
@pkgdatadir@/menu
.sp
~/\&.fluxbox/menu
.sp
~/\&.fluxbox/windowmenu
.SH "SYNTAX"
.sp
Variable parameters are shown in emphasis: \fIargument\fR
.sp
All other characters shown are required verbatim\&. Whitespace is only required to delimit words, but it is fine to add more whitespace\&.
.SH "DESCRIPTION"
.sp
There are two types of menus in fluxbox which can be configured\&.
.sp
The first is the root menu, which normally appears when you right\-click on the desktop\&.
.sp
The first is the \fBROOT MENU\fR (Or right\-click menu), is usually bound to a right\-click on the desktop, though this binding can be changed in the \(oqkeys\(cq file (\fBfluxbox\-keys(5)\fR)\&. This same syntax is used for the \fBCustomMenu\fR command, also mentioned in \fBfluxbox\-keys(5)\fR\&.
.sp
Fluxbox installs a default root menu file in \fB@pkgdatadir@/menu\fR\&. You can also use fluxbox \-i to confirm this location\&. Of course this system\-wide menu can be customized for all users at once, but it is also possible to create an individual menu file for each user\&. By convention, users create a menu file in \fB~/\&.fluxbox/menu\fR\&. Once you\(cqve created your own menu file, you\(cqll want to make sure that you properly declare this location in your \(oqinit\(cq file so that fluxbox knows where to look\&. See \fBRESOURCES\fR, below for details\&.
.sp
The second type is the \fBWINDOW MENU\fR, which defines the contents of the menu which appears when you right\-click on a window\(cqs titlebar or iconbar\&. This opens a menu file as defined by \fB~/\&.fluxbox/windowmenu\fR\&. If this file does not exist, fluxbox will copy in the default from \fB@pkgdatadir@/windowmenu\fR\&.
.sp
You do not need to \(lqreload\(rq fluxbox after editing the apps file, the changes should be taken into account the next time you open the menu\&.
.SH "ROOT MENU"
.sp
The root menu must begin with a \fB[begin]\fR tag and end with an \fB[end]\fR tag, and every tag must be on its own line\&.
.PP
There are up to four fields in a menu line\&. They are of the form
.RS 4
[\fItag\fR] (\fIlabel\fR) {\fIcommand\fR} <\*(Aqicon\*(Aq>
.RE
.sp
The <\*(Aqicon\*(Aq> field is always optional when shown below\&. If specified, the \fIicon\fR will be scaled down and displayed in the menu alongside the text label of the item\&. It must be in \&.xpm or \&.png format\&.
.sp
Any line that starts with a \fI#\fR or \fI!\fR is considered a comment and ignored by fluxbox\&. Also, in the label/command/filename fields you can escape any character\&. Using \fI\e\e\fR inserts a literal back\-slash into the label/command/filename field\&.
.sp
You may enter labels, commands, and icons using characters from any \fBiconv(1)\fR language/locale by specifying the encoding used via the \fB[encoding]\fR tag, detailed below\&.
.SS "Structural Tags"
.PP
\fB[begin]\fR (\fItitle\fR)
.RS 4
This tells fluxbox to start parsing the menu file\&. This tag is required for fluxbox to read your menu file\&. If it cannot find it, the system default menu is used in its place\&. The
\fItitle\fR
appears at the top of the menu\&. And
\fB[end]\fR
tag is required to end the menu\&.
.RE
.PP
\fB[submenu]\fR (\fIlabel\fR) {\fItitle\fR} <\*(Aqicon\*(Aq>
.RS 4
This tells fluxbox to create and parse a new menu, which is inserted as a submenu into the parent menu\&. These menus are parsed recursively, so there is no limit to the number of levels or nested submenus you can have\&. The
\fIlabel\fR
is the text that will appear in the parent menu, and the
\fItitle\fR
is shown at the top of the submenu\&. If omitted, the
\fItitle\fR
will be the same as the
\fIlabel\fR\&. An
\fB[end]\fR
tag is required to end the submenu\&.
.RE
.PP
\fB[end]\fR
.RS 4
This tells fluxbox that it is at the end of a menu\&. This can either be a
\fB[submenu]\fR
or the
\fB[begin]\fR
tag of the main root menu\&. There must be at least one of these tags in your menu to correspond to the required
\fB[begin]\fR
tag, and one for each
\fB[submenu]\fR\&.
.RE
.PP
\fB[encoding]\fR {\fIencoding\fR}
.RS 4
This begins an
\fB[encoding]\fR
section and specifies the string encoding of all strings until the matching
\fB[endencoding]\fR
tag\&. For a list of available encodings on your system, run
\fBiconv \-l\fR\&.
.RE
.PP
\fB[endencoding]\fR
.RS 4
This ends an
\fB[encoding]\fR
section\&.
.RE
.PP
\fB[include]\fR (\fIpath\fR)
.RS 4
Parses the file specified by filename inline with the current menu\&. The
\fIpath\fR
can be the full path to a file or it can begin with
\fB~/\fR, which will be expanded into your home directory\&. If
\fIpath\fR
is a directory, then all files in that directory are included\&.
.RE
.PP
\fB[separator]\fR
.RS 4
This will create a nice separation line\&. Useful for splitting up sections in a \(lqpretty\(rq way\&. The optional
\fIcomment\fR
is not displayed, but can be useful for internal documentation or script parsing of menu files\&.
.RE
.PP
\fB[nop]\fR (\fIlabel\fR) <\*(Aqicon\*(Aq>
.RS 4
Insert a non\-operational item into the current menu\&. This is much like
\fB[separator]\fR, but instead of a line, it inserts a
\fIlabel\fR\&. This can be used to help format the menu into blocks or sections if so desired\&. The
\fIlabel\fR
is optional, and if omitted a blank item will be inserted\&.
.RE
.SS "Applications"
.PP
\fB[exec]\fR (\fIlabel\fR) {\fIcommand\&...\fR} <\*(Aqicon\*(Aq>
.RS 4
Inserts a command item into the menu\&. When you select the menu item from the menu, fluxbox runs
\fIcommand\&...\fR
in your
\fB$SHELL\fR
(or /bin/sh if $SHELL is not set)\&. You can use this to launch applications, run shell scripts, etc\&. Since all arguments are passed verbatim to the shell, you can use environment variables, pipes, or anything else the shell can do\&. Note that processes only see environment variables that were set before fluxbox started (such as in ~/\&.fluxbox/startup)\&.
.RE
.SS "Fluxbox Functions"
.PP
\fB[config]\fR (\fIlabel\fR) <\*(Aqicon\*(Aq>
.RS 4
Inserts a fluxbox native submenu item, containing numerous configuration options concerning window placement, focus style, window moving style, etc\&. See
\fBConfiguration Menu\fR
in
\fBfluxbox(1)\fR
for details\&.
.RE
.PP
\fB[reconfig]\fR (\fIlabel\fR) <\*(Aqicon\*(Aq>
.RS 4
When selected this item re\-reads the current style and menu files and applies any changes\&. This is useful for creating a new style or theme, as you don\(cqt have to constantly restart fluxbox every time you save your style\&. However, fluxbox automatically rereads the menu whenever it changes\&.
.RE
.PP
\fB[restart]\fR (\fIlabel\fR) {\fIcommand\fR} <\*(Aqicon\*(Aq>
.RS 4
This tells fluxbox to restart\&. If
\fIcommand\fR
is supplied, it shuts down and runs the command (which is commonly the name of another window manager)\&. If
\fIcommand\fR
is omitted, fluxbox restarts itself\&.
.RE
.PP
\fB[exit]\fR (\fIlabel\fR) <\*(Aqicon\*(Aq>
.RS 4
Inserts an item that shuts down and exits fluxbox\&. Any open windows are reparented to the root window before fluxbox exits\&.
.RE
.PP
\fB[style]\fR (\fIlabel\fR) {\fIfilename\fR} <\*(Aqicon\*(Aq>
.RS 4
This tells fluxbox to insert an item that, when selected, reads style file named filename and apply the new textures, colors and fonts to the current running session\&.
.RE
.PP
\fB[stylesmenu]\fR (\fIdirectory\fR) <\*(Aqicon\*(Aq>
.RS 4
Reads all filenames from the specified directory, assuming that they are all valid style files, and creates inline menu items in the current menu for every filename, that, when selected by the user will apply the selected style file to the current session\&. The labels that are created in the menu are the filenames of the style files\&.
.RE
.PP
\fB[stylesdir]\fR (\fIlabel\fR) {\fIdirectory\fR} <\*(Aqicon\*(Aq>
.RS 4
Creates a submenu entry with
\fIlabel\fR
(that is also the title of the new submenu), and inserts in that submenu all filenames in the specified
\fIdirectory\fR, assuming that they are all valid style files (directories are ignored) in the same way as the
\fB[stylesdir]\fR
command does\&. Both
\fB[stylesdir]\fR
and
\fB[stylesmenu]\fR
commands make it possible to install style files without editing your init file\&.
.RE
.PP
\fB[wallpapers]\fR (\fIdirectory\fR) {\fIcommand\fR} <\*(Aqicon\*(Aq>
.RS 4
This inserts a menu item to set the wallpaper for each file in the given directory\&. The
\fIcommand\fR
is optional, and defaults to
\fBfbsetbg\fR\&.
.RE
.PP
\fB[workspaces]\fR (\fIlabel\fR) <\*(Aqicon\*(Aq>
.RS 4
This tells fluxbox to insert a link to the workspaces menu directly into your menu\&. See
\fBWorkspace Menu\fR
in
\fBfluxbox(1)\fR
for details\&.
.RE
.PP
\fB[\fR\fIcommand\fR\fB]\fR (\fIlabel\fR) <\*(Aqicon\*(Aq>
.RS 4
In addition to the commands above, any legal keys file
\fIcommand\fR
may be used as a menu item\&. See
\fBfluxbox\-keys(5)\fR
for more information\&.
.RE
.SH "WINDOW MENU"
.sp
Like the \fBROOT MENU\fR, this menu file must start with \fB[begin]\fR and end with \fB[end]\fR\&. However, this file consists of only one \fB[\fR\fItag\fR\fB]\fR per line with no labels, commands, or icons\&.
.sp
The available tags in this menu are:
.PP
\fB[shade]\fR
.RS 4
Provides a menu item to shade or unshade (or, roll\-up) the window\&. This is equivalent to the shade titlebar button\&.
.RE
.PP
\fB[stick]\fR
.RS 4
Provides a menu item to stick or unstick the window\&. Stuck windows are displayed on all workspaces\&. This is equivalent to the stick titlebar button\&.
.RE
.PP
\fB[maximize]\fR
.RS 4
Provides a menu item to maximize or unmaximize the window, equivalent to the maximize titlebar button\&. The button with which you click alters the behaviour of this item as follows:
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
Button 1 (Un)Maximize as normal\&.
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
Button 2 (Un)Maximize window vertically\&.
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
Button 3 (Un)Maximize window horizontally\&.
.RE
.RE
.PP
\fB[iconify]\fR
.RS 4
Provides a menu item to iconify (or, minimize) the window, equivalent to the iconify titlebar button\&.
.RE
.PP
\fB[close]\fR
.RS 4
Closes the window gracefully, equivalent to the titlebar button\&.
.RE
.PP
\fB[kill]\fR
.RS 4
Kills the window\(cqs process, like
\fBxkill(1)\fR\&.
.RE
.PP
\fB[raise]\fR
.RS 4
Raise the window to the top of the stack within its layer\&.
.RE
.PP
\fB[lower]\fR
.RS 4
Lower the window to the bottom of the stack within its layer\&.
.RE
.PP
\fB[settitledialog]\fR
.RS 4
Opens a dialog which can be used to set the window\(cqs title\&. Some applications may re\-set their own title from time\-to\-time, wiping out your setting\&.
.RE
.PP
\fB[sendto]\fR
.RS 4
Sends the window to a different workspace\&. When you select the workspace with a middle\-click, fluxbox will also change to the new workspace\&. A regular click only sends the window\&.
.RE
.PP
\fB[layer]\fR
.RS 4
Adds a \(lqLayer\&...\(rq submenu which lets you change the layer of this window\&.
.RE
.PP
\fB[alpha]\fR
.RS 4
Adds a \(lqTransparency\&...\(rq submenu which lets you change the focused and unfocused transparency of this window\&.
.RE
.PP
\fB[extramenus]\fR
.RS 4
Adds the \(lqRemember\&...\(rq menu item, which allows you to specify which settings should be stored in the \(oqapps\(cq file (See
\fBfluxbox\-apps(5)\fR
for more details)\&.
.RE
.PP
\fB[separator]\fR
.RS 4
Adds a horizontal line to the menu
.RE
.SH "FILES"
.PP
\fB~/\&.fluxbox/menu\fR
.RS 4
This is the default location for the user\(cqs root menu\&.
.RE
.PP
\fB@pkgdatadir@/menu\fR
.RS 4
This is the system\-wide root menu file\&. It will be used if the user\(cqs root menu is missing or unparseable\&.
.RE
.PP
\fB~/\&.fluxbox/windowmenu\fR
.RS 4
This is the user\(cqs window menu definition file
.RE
.PP
\fB@pkgdatadir@/menu\fR
.RS 4
This is the default window menu\&. If the user does not have this file, it will be copied to
\fB~/\&.fluxbox/windowmenu\fR
on fluxbox startup\&.
.RE
.SH "RESOURCES"
.PP
\fBsession\&.menuFile:\fR \fIlocation\fR
.RS 4
This may be set to override the location of the user\(cqs root menu\&.
.RE
.SH "ENVIRONMENT"
.sp
The \fIcomand\&...\fR field of the \fB[exec]\fR tag can take advantage of other environment variables if they are set before fluxbox is started\&.
.SH "EXAMPLES"
.PP
\fBRoot Menu\fR. 
.sp
.if n \{\
.RS 4
.\}
.nf
# fluxbox menu file
[begin] (fluxbox)
    [exec] (rxvt) {rxvt \-ls} </usr/X11R6/share/icons/terminal\&.xpm>
    [exec] (netscape) {netscape \-install}
    [exec] (The GIMP) {gimp}
    [exec] (XV) {xv}
    [exec] (Vim) {rxvt \-geometry 132x60 \-name VIM \-e screen vim}
    [exec] (Mutt) {rxvt \-name mutt \-e mutt}
    [submenu] (mozilla)
        [exec] (browser) {mozilla \-browser}
        [exec] (news) {mozilla \-news}
        [exec] (mail) {mozilla \-mail}
        [exec] (edit) {mozilla \-edit}
        [exec] (compose) {mozilla \-compose}
    [end]
    [submenu] (Window Manager)
        [exec] (Edit Menus) {nedit ~/\&.fluxbox/menu}
        [submenu] (Style) {Which Style?}
            [stylesdir] (~/\&.fluxbox/styles)
            [stylesmenu] (fluxbox Styles) {@pkgdatadir@/styles}
        [end]
        [config] (Config Options)
        [reconfig] (Reconfigure)
        [restart] (Restart)
    [end]
    [exit] (Log Out)
[end]
.fi
.if n \{\
.RE
.\}
.PP
\fBDefault Window Menu\fR. 
.sp
.if n \{\
.RS 4
.\}
.nf
[begin]
  [shade]
  [stick]
  [maximize]
  [iconify]
  [raise]
  [lower]
  [settitledialog]
  [sendto]
  [layer]
  [alpha]
  [extramenus]
  [separator]
  [close]
[end]
.fi
.if n \{\
.RE
.\}
.sp
.SH "AUTHORS"
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
Jim Ramsay <i\&.am at jimramsay com> (>fluxbox\-1\&.0\&.0)
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
Curt Micol <asenchi at asenchi com> (>fluxbox\-0\&.9\&.11)
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
Tobias Klausmann <klausman at users sourceforge net> (\(lafluxbox\-0\&.9\&.11)
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
Grubert <grubert at users sourceforge net> (fluxbox)
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
Matthew Hawkins <matt at mh dropbear id au> (blackbox)
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
Wilbert Berendsen <wbsoft at xs4all nl> (blackbox)
.RE
.SH "SEE ALSO"
.sp
fluxbox(1) fluxbox\-keys(5) fluxbox\-apps(5) xkill(1) iconv(1)
.SH "AUTHOR"
.PP
\fBJim Ramsay\fR <\&i\&.am@jimramsay\&.com\&>
.RS 4
Author.
.RE