]> code.delx.au - spectrwm/blobdiff - spectrwm.1
Convert all booleans to stdbool.h bool.
[spectrwm] / spectrwm.1
index 1390ca0372362c1dac15a285fa3410a568222b90..bc2ed7f8e4f9fd06d90fbf440df41e3162fcf943 100644 (file)
@@ -1,6 +1,6 @@
 .\" Copyright (c) 2009-2012 Marco Peereboom <marco@peereboom.us>
 .\" Copyright (c) 2009 Darrin Chandler <dwchandler@stilyagin.com>
-.\" Copyright (c) 2011-2013 Reginald Kennedy <rk@rejii.com>
+.\" Copyright (c) 2011-2014 Reginald Kennedy <rk@rejii.com>
 .\" Copyright (c) 2011-2012 Lawrence Teo <lteo@lteo.net>
 .\" Copyright (c) 2011-2012 Tiago Cunha <tcunha@gmx.com>
 .\" Copyright (c) 2012 David Hill <dhill@mindcry.org>
@@ -152,7 +152,6 @@ manpages.
 The
 .Xr xfontsel 1
 application can help with the XLFD setting.
-.Pp
 .It Ic bar_font_color Ns Bq Ar x
 Color of the font in status bar in screen
 .Ar x .
@@ -170,17 +169,18 @@ It may contain the following character sequences:
 .It Sy "Character sequence" Ta Sy "Replaced with"
 .It Li "+<" Ta "Pad with a space"
 .It Li "+A" Ta "Output of the external script"
-.It Li "+C" Ta "Window class"
+.It Li "+C" Ta "Window class (from WM_CLASS)"
 .It Li "+D" Ta "Workspace name"
 .It Li "+F" Ta "Floating indicator"
 .It Li "+I" Ta "Workspace index"
+.It Li "+M" Ta "Number of iconic (minimized) windows in workspace"
 .It Li "+N" Ta "Screen number"
-.It Li "+P" Ta "Window class and title separated by a colon"
+.It Li "+P" Ta "Window class and instance separated by a colon"
 .It Li "+S" Ta "Stacking algorithm"
-.It Li "+T" Ta "Window title"
+.It Li "+T" Ta "Window instance (from WM_CLASS)"
 .It Li "+U" Ta "Urgency hint"
 .It Li "+V" Ta "Program version"
-.It Li "+W" Ta "Window name"
+.It Li "+W" Ta "Window name (from _NET_WM_NAME/WM_NAME)"
 .It Li "++" Ta "A literal" Ql +
 .El
 .Pp
@@ -221,10 +221,19 @@ Disable by setting to 0
 so a custom clock could be used in the
 .Pa bar_action
 script.
+.It Ic iconic_enabled
+Display the number of iconic (minimized) windows in the status bar.
+Enable by setting to 1.
 .It Ic color_focus
-Border color of the currently focussed window.
+Border color of the currently focused window.  Default is red.
+.It Ic color_focus_maximized
+Border color of the currently focused, maximized window.  Defaults to the
+value of color_focus.
 .It Ic color_unfocus
-Border color of unfocussed windows.
+Border color of unfocused windows, default is rgb:88/88/88.
+.It Ic color_unfocus_maximized
+Border color of unfocused, maximized windows.  Defaults to the value of
+color_unfocus.
 .It Ic dialog_ratio
 Some applications have dialogue windows that are too small to be useful.
 This ratio is the screen size to what they will be resized.
@@ -266,6 +275,9 @@ and changes to layout.
 .It Cm manual
 Set window focus on window interaction only.
 .El
+.It Ic java_workaround
+Workaround a Java GUI rendering issue on non-reparenting window managers by
+impersonating LG3D window manager, written by Sun. Default is 1.
 .It Ic keyboard_mapping
 Clear all key bindings and load new key bindings from the specified file.
 This allows you to load pre-defined key bindings for your keyboard layout.
@@ -275,7 +287,7 @@ section below for a list of keyboard mapping files that have been provided
 for several keyboard layouts.
 .It Ic layout
 Select layout to use at start-of-day. Defined in the format
-ws[idx]:master_grow:master_add:stack_inc:layout:always_raise:stack_mode, e.g.
+ws[idx]:master_grow:master_add:stack_inc:always_raise:stack_mode, e.g.
 ws[2]:-4:0:1:0:horizontal sets worskspace 2 to the horizontal stack mode and
 shrinks the master area by 4 ticks and adds one window to the stack, while
 maintaining default floating window behavior.
@@ -306,15 +318,22 @@ This setting is not retained at restart.
 .It Ic modkey
 Change mod key.
 Mod1 is generally the ALT key and Mod4 is the windows key on a PC.
+.It Ic name
+Set the name of a workspace at start-of-day.
+Defined in the format ws[<idx>]:<name>, e.g. ws[1]:Console sets the name of
+workspace 1 to
+.Dq Console .
 .It Ic program Ns Bq Ar p
 Define new action to spawn a program
 .Ar p .
 See the
 .Sx PROGRAMS
 section below.
-.It Ic quirk Ns Bq Ar c:n
+.It Ic quirk Ns Bq Ar c:i:n
 Add "quirk" for windows with class
-.Ar c
+.Ar c ,
+instance
+.Ar i
 and name
 .Ar n .
 See the
@@ -369,20 +388,15 @@ binary without the setgid bit set.
 Pixel width of empty space between tiled windows.  Negative values cause overlap.
 Set this to the opposite of border_width to collapse the border between tiles.
 Disable by setting to 0.
-.It Ic title_class_enabled
-Enable or disable displaying the window class in the status bar.
-Enable by setting to 1.
-.It Ic title_name_enabled
-Enable or disable displaying the window title in the status bar.
-Enable by setting to 1.
 .It Ic urgent_enabled
-Enable or disable the urgency hint.
-Note that many terminal emulators require this to be enabled for it to
-propagate.
-In xterm, for example, one needs to add the following line
-.Pa xterm.bellIsUrgent: true
-to
-.Pa .Xdefaults .
+Enable or disable the urgency hint indicator in the status bar.
+Note that many terminal emulators require an explicit setting for the bell
+character to trigger urgency on the window.  In xterm, for example, one needs to
+add the following line to
+.Pa .Xdefaults :
+.Bd -literal -offset indent
+xterm.bellIsUrgent: true
+.Ed
 .It Ic verbose_layout
 Enable or disable displaying the current master window count and stack column/row
 count in the status bar.
@@ -394,9 +408,15 @@ See
 and
 .Pa stack_dec
 for more information.
+.It Ic window_class_enabled
+Enable or disable displaying the window class name (from WM_CLASS) in the
+status bar.  Enable by setting to 1.
+.It Ic window_instance_enabled
+Enable or disable displaying the window instance name (from WM_CLASS) in the
+status bar.  Enable by setting to 1.
 .It Ic window_name_enabled
-Enable or disable displaying the window name in the status bar.
-Enable by setting to 1.
+Enable or disable displaying the window display name (from _NET_WM_NAME/WM_NAME)
+in the status bar.  Enable by setting to 1.
 .Pp
 To prevent excessively large window names from pushing the remaining text off
 the bar, it's limited to 64 characters, by default.
@@ -439,6 +459,8 @@ is spawned:
 .It Cm $bar_font_color
 .It Cm $color_focus
 .It Cm $color_unfocus
+.It Cm $dmenu_bottom
+-b if bar_at_bottom is enabled.
 .It Cm $region_index
 .It Cm $workspace_index
 .El
@@ -459,7 +481,7 @@ Default programs:
 .It Cm lock
 xlock
 .It Cm menu
-dmenu_run \-fn $bar_font \-nb $bar_color \-nf $bar_font_color \-sb
+dmenu_run $dmenu_bottom \-fn $bar_font \-nb $bar_color \-nf $bar_font_color \-sb
 $bar_border \-sf $bar_color
 .It Cm term
 xterm
@@ -548,6 +570,8 @@ focus_next
 focus_prev
 .It Cm M-m
 focus_main
+.It Cm M-u
+focus_urgent
 .It Cm M-S-j
 swap_next
 .It Cm M-S-k
@@ -602,6 +626,8 @@ initscr
 iconify
 .It Cm M-S-w
 uniconify
+.It Cm M-e
+maximize_toggle
 .It Cm M-S-r
 always_raise
 .It Cm M-v
@@ -675,6 +701,8 @@ Focus next window in workspace.
 Focus previous window in workspace.
 .It Cm focus_main
 Focus on main window in workspace.
+.It Cm focus_urgent
+Focus on next window with the urgency hint flag set.  The workspace is switched if needed.
 .It Cm swap_next
 Swap with next window in workspace.
 .It Cm swap_prev
@@ -756,7 +784,9 @@ above).
 .It Cm iconify
 Minimize (unmap) currently focused window.
 .It Cm uniconify
-Maximize (map) window returned by dmenu selection.
+Restore (map) window returned by dmenu selection.
+.It Cm maximize_toggle
+Toggle maximization of focused window.
 .It Cm always_raise
 When set tiled windows are allowed to obscure floating windows.
 .It Cm button2
@@ -808,16 +838,16 @@ specify MOD as the modifier key.
 .Pp
 Multiple key combinations may be bound to the same action.
 .Pp
-To bind non-latin characters such as å or π you must enter the xkb
+To bind non-latin characters such as \[oa] or \[*p] you must enter the xkb
 character name instead of the character itself. Run xev, focus the window
 and press the specific key and in the terminal output read the symbol name.
-In the fallowing example for å:
+In the following example for \[oa]:
 .Bd -literal -offset indent
 KeyPress event, serial 41, synthetic NO, window 0x2600001,
     root 0x15a, subw 0x0, time 106213808, (11,5), root:(359,823),
     state 0x0, keycode 24 (keysym 0xe5, aring), same_screen YES,
-    XLookupString gives 2 bytes: (c3 a5) "å"
-    XmbLookupString gives 2 bytes: (c3 a5) "å"
+    XLookupString gives 2 bytes: (c3 a5) "\[oa]"
+    XmbLookupString gives 2 bytes: (c3 a5) "\[oa]"
     XFilterEvent returns: False
 .Ed
 .Pp
@@ -909,30 +939,60 @@ Has no effect when
 is set to follow.
 .It FOCUSONMAP_SINGLE
 When the window first appears on the screen, change focus to the window
-if there are no other windows on the workspace with the same class/name.
-Has no effect when
+if there are no other windows on the workspace with the same WM_CLASS
+class/instance value.  Has no effect when
 .Ic focus_mode
 is set to follow.
+.It OBEYAPPFOCUSREQ
+When an application requests focus on the window via a _NET_ACTIVE_WINDOW
+client message (source indication of 1), comply with the request.
+Note that a source indication of 0 (unspecified) or 2 (pager) are always
+obeyed.
+.It IGNOREPID
+Ignore the PID when determining the initial workspace for a new window.
+Especially useful for terminal windows that share a process.
+.It IGNORESPAWNWS
+Ignore the spawn workspace when determining the initial workspace for a
+new window.
 .El
 .Pp
 Custom quirks in the configuration file are specified as follows:
 .Pp
-.Dl quirk[<class>:<name>] = <quirk> [ + <quirk> ... ]
+.Dl quirk[<class>[:<instance>[:<name>]]] = <quirk> [ + <quirk> ... ]
 .Pp
-.Aq class
-and
+.Aq class ,
+.Aq instance
+(optional) and
 .Aq name
-specify the window to which the quirk(s) apply, and
+(optional) are patterns used to determine which window(s) the quirk(s) apply
+and
 .Aq quirk
 is one of the quirks from the list above.
+.Pp
+Note that patterns are interpreted as POSIX Extended Regular Expressions.
+Any ':', '[' or ']' must be escaped with '\\'.
+See
+.Xr regex 7
+for more information on POSIX Extended Regular Expressions.
+.Pp
 For example:
 .Bd -literal -offset indent
-quirk[MPlayer:xv] = FLOAT + FULLSCREEN + FOCUSPREV
-quirk[pcb:pcb] = NONE  # remove existing quirk
+quirk[MPlayer] = FLOAT + FULLSCREEN + FOCUSPREV # Float all windows having a \
+class of 'MPlayer'
+quirk[.*] = FLOAT # Float all windows by default.
+quirk[.*:.*:.*] = FLOAT # Same as above.
+quirk[Firefox:Navigator] = FLOAT # Float all Firefox browser windows.
+quirk[::Console] = FLOAT # Float windows with WM_CLASS not set and a \
+window name of 'Console'.
+quirk[\\[0-9\\].*:.*:\\[\\[\\:alnum\\:\\]\\]*] = FLOAT # Float windows with WM_CLASS \
+class beginning with a number, any WM_CLASS instance and a \
+_NET_WM_NAME/WM_NAME either blank or containing alphanumeric characters without spaces.
+quirk[pcb:pcb] = NONE # remove existing quirk
 .Ed
 .Pp
 You can obtain
-.Aq class
+.Aq class ,
+.Aq instance
 and
 .Aq name
 by running
@@ -940,11 +1000,18 @@ by running
 and then clicking on the desired window.
 In the following example the main window of Firefox was clicked:
 .Bd -literal -offset indent
-$ xprop | grep WM_CLASS
+$ xprop | grep -E "^(WM_CLASS|_NET_WM_NAME|WM_NAME)"
 WM_CLASS(STRING) = "Navigator", "Firefox"
+WM_NAME(STRING) = "spectrwm - ConformalOpenSource"
+_NET_WM_NAME(UTF8_STRING) = "spectrwm - ConformalOpenSource"
 .Ed
 .Pp
-Note that grepping for WM_CLASS flips class and name.
+Note that
+.Xr xprop 1
+displays WM_CLASS as:
+.Bd -literal -offset indent
+WM_CLASS(STRING) = "<instance>", "<class>"
+.Ed
 In the example above the quirk entry would be:
 .Bd -literal -offset indent
 quirk[Firefox:Navigator] = FLOAT
@@ -995,7 +1062,7 @@ and
 .Xr grep 1 :
 .Bd -literal -offset indent
 $ WINDOWID=`xprop \-root _NET_ACTIVE_WINDOW | grep \-o "0x.*"`
-$ xprop \-id $WINDOWID WM_NAME | grep \-o "\\".*\\""
+$ xprop \-id $WINDOWID _NET_WM_NAME | grep \-o "\\".*\\""
 .Ed
 .Pp
 A window can be focused by sending a _NET_ACTIVE_WINDOW client message
@@ -1031,6 +1098,12 @@ or un-floated):
 $ wmctrl \-i \-r 0x4a0000b \-b toggle,_NET_WM_STATE_ABOVE
 .Ed
 .Pp
+Windows can also be iconified and un-iconified by substituting
+_NET_WM_STATE_HIDDEN for _NET_WM_STATE_ABOVE in the previous example:
+.Bd -literal -offset indent
+$ wmctrl \-i \-r 0x4a0000b \-b toggle,_NET_WM_STATE_HIDDEN
+.Ed
+.Pp
 Floating windows can also be resized and moved by sending a
 _NET_MOVERESIZE_WINDOW client message to the root window.
 For example,