JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
mention Czech Republic keyboard mapping file scrotwm_cz.conf on manpage
[spectrwm.git] / scrotwm.1
1 .\" Copyright (c) 2009 Marco Peereboom <marco@peereboom.us>
2 .\" Copyright (c) 2009 Darrin Chandler <dwchandler@stilyagin.com>
3 .\"
4 .\" Permission to use, copy, modify, and distribute this software for any
5 .\" purpose with or without fee is hereby granted, provided that the above
6 .\" copyright notice and this permission notice appear in all copies.
7 .\"
8 .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9 .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10 .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11 .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12 .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13 .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14 .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15 .\"
16 .Dd $Mdocdate: November 11 2011 $
17 .Dt SCROTWM 1
18 .Os
19 .Sh NAME
20 .Nm scrotwm
21 .Nd window manager for X11
22 .Sh SYNOPSIS
23 .Nm scrotwm
24 .Sh DESCRIPTION
25 .Nm
26 is a minimalistic window manager that tries to stay out of the way so that
27 valuable screen real estate can be used for much more important stuff.
28 It has sane defaults and does not require one to learn a language to do any
29 configuration.
30 It was written by hackers for hackers and it strives to be small, compact and
31 fast.
32 .Pp
33 When
34 .Nm
35 starts up, it reads settings from its configuration file,
36 .Pa scrotwm.conf .
37 See the
38 .Sx CONFIGURATION FILES
39 section below.
40 .Pp
41 The following notation is used throughout this page:
42 .Pp
43 .Bl -tag -width Ds -offset indent -compact
44 .It Cm M
45 Meta
46 .It Cm S
47 Shift
48 .It Aq Cm Name
49 Named key
50 .It Cm M1
51 Mouse button 1
52 .It Cm M3
53 Mouse button 3
54 .El
55 .Pp
56 .Nm
57 is very simple in its use.
58 Most of the actions are initiated via key or mouse bindings.
59 See the
60 .Sx BINDINGS
61 section below for defaults and customizations.
62 .Sh CONFIGURATION FILES
63 .Nm
64 first tries to open the user specific file,
65 .Pa ~/.scrotwm.conf .
66 If that file is unavailable,
67 it then tries to open the global configuration file
68 .Pa /etc/scrotwm.conf .
69 .Pp
70 The format of the file is \*(Ltkeyword\*(Gt = \*(Ltsetting\*(Gt.
71 For example:
72 .Pp
73 .Dl color_focus = red
74 .Pp
75 Enabling or disabling an option is done by using 1 or 0 respectively.
76 .Pp
77 The file supports the following keywords:
78 .Pp
79 .Bl -tag -width "title_class_enabledXXX" -offset indent -compact
80 .It Cm autorun
81 Launch an application in a specified workspace at start-of-day.
82 Defined in the format ws[<idx>]:application, e.g. ws[2]:xterm launches an
83 xterm in workspace 2.
84 .It Cm color_focus
85 Border color of the currently focussed window.
86 .It Cm color_unfocus
87 Border color of unfocussed windows.
88 .It Cm bar_enabled
89 Enable or disable status bar.
90 .It Cm bar_border Ns Bq Ar x
91 Color of the status bar border in screen
92 .Ar x .
93 .It Cm bar_border_width
94 Set status bar border thickness in pixels.
95 Disable border by setting to 0.
96 .It Cm bar_color Ns Bq Ar x
97 Color of the status bar window in screen
98 .Ar x .
99 .It Cm bar_font_color Ns Bq Ar x
100 Color of the font in status bar in screen
101 .Ar x .
102 .It Cm bar_font
103 Status bar font.
104 .It Cm bar_action
105 External script that populates additional information in the status bar,
106 such as battery life.
107 .It Cm bar_delay
108 Update frequency, in seconds, of external script that populates the status bar.
109 .It Cm bar_at_bottom
110 Place the statusbar at the bottom of each region instead of the top.
111 .It Cm stack_enabled
112 Enable or disable displaying the current stacking algorithm in the status bar.
113 .It Cm clock_enabled
114 Enable or disable displaying the clock in the status bar.
115 Disable by setting to 0
116 so a custom clock could be used in the
117 .Pa bar_action
118 script.
119 .It Cm dialog_ratio
120 Some applications have dialogue windows that are too small to be useful.
121 This ratio is the screen size to what they will be resized.
122 For example, 0.6 is 60% of the physical screen size.
123 .It Cm keyboard_mapping
124 Clear all key bindings and load new key bindings from the specified file.
125 This allows you to load pre-defined key bindings for your keyboard layout.
126 At present, keyboard mapping files for the US, Czech Republic, French and
127 Spanish keyboards are provided in scrotwm_us.conf, scrotwm_cz.conf,
128 scrotwm_fr.conf and scrotwm_es.conf respectively.
129 .It Cm layout
130 Select layout to use at start-of-day.
131 Defined in the format
132 ws[idx]:master_grow:master_add:stack_inc:layout:always_raise:stack_mode, e.g.
133 ws[2]:-4:0:1:0:horizontal sets worskspace 2 to the horizontal stack mode and
134 shrinks the master area by 4 ticks and adds one window to the stack, while
135 maintaining default floating window behavior.
136 Possible stack_mode values are
137 .Pa vertical ,
138 .Pa horizontal
139 and
140 .Pa fullscreen .
141 .Pp
142 See
143 .Pa master_grow ,
144 .Pa master_shrink ,
145 .Pa master_add ,
146 .Pa master_del ,
147 .Pa stack_inc ,
148 .Pa stack_del ,
149 and
150 .Pa always_raise
151 for more information.
152 Note that the stacking options are complicated and have side-effects.
153 One should familiarize oneself with these commands before experimenting with the
154 .Pa layout
155 option.
156 .Pp
157 This setting is not retained at restart.
158 .It Cm region
159 Allocates a custom region, removing any autodetected regions which occupy the same
160 space on the screen.
161 Defined in the format screen[<idx>]:WIDTHxHEIGHT+X+Y,
162 e.g.\& screen[1]:800x1200+0+0.
163 .Pp
164 To make a screen span multiple monitors, create a region big enough to cover
165 them all, e.g. screen[1]:2048x768+0+0 makes the screen span two monitors with
166 1024x768 resolution sitting one next to the other.
167 .It Cm term_width
168 Set a preferred minimum width for the terminal.
169 If this value is greater than 0,
170 .Nm
171 will attempt to adjust the font sizes in the terminal to keep the terminal
172 width above this number as the window is resized.
173 Only
174 .Xr xterm 1
175 is currently supported.
176 The
177 .Xr xterm 1
178 binary must not be setuid or setgid, which it is by default on most systems.
179 Users may need to set program[term] (see the
180 .Sx PROGRAMS
181 section) to use an alternate copy of the
182 .Xr xterm 1
183 binary without the setgid bit set.
184 .It Cm title_class_enabled
185 Enable or disable displaying the window class in the status bar.
186 Enable by setting to 1.
187 .It Cm title_name_enabled
188 Enable or disable displaying the window title in the status bar.
189 Enable by setting to 1.
190 .It Cm urgent_enabled
191 Enable or disable the urgency hint.
192 Note that many terminal emulators require this to be enabled for it to
193 propagate.  In xterm, for example, one needs to add the following line
194 .Pa xterm.urgentOnBell: true
195 to
196 .Pa .Xdefaults .
197 .It Cm window_name_enabled
198 Enable or disable displaying the window name in the status bar.
199 Enable by setting to 1.
200 .It Cm verbose_layout
201 Enable or disable displaying the current master and stack values in the status
202 bar.
203 Enable by setting to 1.
204 .It Cm modkey
205 Change mod key.
206 Mod1 is generally the ALT key and Mod4 is the windows key on a PC.
207 .It Cm focus_mode
208 Using a value of
209 .Pa follow_cursor
210 will make the window manager focus the window
211 under the mouse when switching workspaces and creating windows.
212 .It Cm disable_border
213 Remove border when bar is disabled and there is only one window on the screen.
214 .It Cm border_width
215 Set window border thickness in pixels.
216 Disable all borders by setting to 0.
217 .It Cm program Ns Bq Ar p
218 Define new action to spawn a program
219 .Ar p .
220 See the
221 .Sx PROGRAMS
222 section below.
223 .It Cm bind Ns Bq Ar x
224 Bind key combo to action
225 .Ar x .
226 See the
227 .Sx BINDINGS
228 section below.
229 .It Cm quirk Ns Bq Ar c:n
230 Add "quirk" for windows with class
231 .Ar c
232 and name
233 .Ar n .
234 See the
235 .Sx QUIRKS
236 section below.
237 .El
238 .Pp
239 Colors need to be specified per the
240 .Xr XQueryColor 3
241 specification and fonts need to be specified per the
242 .Xr XQueryFont 3
243 specification.
244 .Pp
245 To list the available fonts in your system see
246 .Xr fc-list 1
247 or
248 .Xr xlsfonts 1
249 manpages.
250 The
251 .Xr xfontsel 1
252 application can help you to show the X Logical Font Description ("XLFD") used
253 as setting in the keyword
254 .Pa bar_font .
255 .Sh PROGRAMS
256 .Nm
257 allows you to define custom actions to launch programs of your choice and then
258 bind them the same as with built-in actions.
259 See the
260 .Sx BINDINGS
261 section below.
262 .Pp
263 The default programs are described below:
264 .Pp
265 .Bl -tag -width "screenshot_wind" -offset indent -compact
266 .It Cm term
267 xterm
268 .It Cm screenshot_all
269 screenshot.sh full
270 .It Cm screenshot_wind
271 screenshot.sh window
272 .It Cm lock
273 xlock
274 .It Cm initscr
275 initscreen.sh
276 .It Cm menu
277 dmenu_run \-fn $bar_font \-nb $bar_color \-nf $bar_font_color \-sb $bar_border \-sf $bar_color
278 .El
279 .Pp
280 Custom programs in the configuration file are specified as follows:
281 .Pp
282 .Dl program[<name>] = <progpath> [<arg> [... <arg>]]
283 .Pp
284 .Aq name
285 is any identifier that does not conflict with a built-in action or keyword,
286 .Aq progpath
287 is the desired program, and
288 .Aq arg
289 is zero or more arguments to the program.
290 .Pp
291 The following variables represent settable values in
292 .Nm
293 (see the
294 .Sx CONFIGURATION FILES
295 section above),
296 and may be used in the
297 .Aq arg
298 fields and will be substituted for values at the time the program is spawned:
299 .Pp
300 .Bl -tag -width "$bar_font_color" -offset indent -compact
301 .It Cm $bar_border
302 .It Cm $bar_color
303 .It Cm $bar_font
304 .It Cm $bar_font_color
305 .It Cm $color_focus
306 .It Cm $color_unfocus
307 .El
308 .Pp
309 Example:
310 .Bd -literal -offset indent
311 program[ff] = /usr/local/bin/firefox http://scrotwm.org/
312 bind[ff] = Mod+f # Now Mod+F launched firefox
313 .Ed
314 .Pp
315 To undo the previous:
316 .Bd -literal -offset indent
317 bind[] = Mod+f
318 program[ff] =
319 .Ed
320 .Sh BINDINGS
321 .Nm
322 provides many functions (or actions) accessed via key or mouse bindings.
323 .Pp
324 The current mouse bindings are described below:
325 .Pp
326 .Bl -tag -width "M-j, M-<TAB>XXX" -offset indent -compact
327 .It Cm M1
328 Focus window
329 .It Cm M-M1
330 Move window
331 .It Cm M-M3
332 Resize window
333 .It Cm M-S-M3
334 Resize window while maintaining it centered
335 .El
336 .Pp
337 The default key bindings are described below:
338 .Pp
339 .Bl -tag -width "M-j, M-<TAB>XXX" -offset indent -compact
340 .It Cm M-S- Ns Aq Cm Return
341 term
342 .It Cm M-p
343 menu
344 .It Cm M-S-q
345 quit
346 .It Cm M-q
347 restart
348 .It Cm M- Ns Aq Cm Space
349 cycle_layout
350 .It Cm M-S- Ns Aq Cm Space
351 reset_layout
352 .It Cm M-h
353 master_shrink
354 .It Cm M-l
355 master_grow
356 .It Cm M-,
357 master_add
358 .It Cm M-.
359 master_del
360 .It Cm M-S-,
361 stack_inc
362 .It Cm M-S-.
363 stack_del
364 .It Cm M- Ns Aq Cm Return
365 swap_main
366 .It Xo
367 .Cm M-j ,
368 .Cm M- Ns Aq Cm TAB
369 .Xc
370 focus_next
371 .It Xo
372 .Cm M-k ,
373 .Cm M-S- Ns Aq Cm TAB
374 .Xc
375 focus_prev
376 .It Cm M-m
377 focus_main
378 .It Cm M-S-j
379 swap_next
380 .It Cm M-S-k
381 swap_prev
382 .It Cm M-b
383 bar_toggle
384 .It Cm M-x
385 wind_del
386 .It Cm M-S-x
387 wind_kill
388 .It Cm M- Ns Aq Ar n
389 ws_ Ns Ar n
390 .It Cm M-S- Ns Aq Ar n
391 mvws_ Ns Ar n
392 .It Cm M- Ns Aq Cm Right
393 ws_next
394 .It Cm M- Ns Aq Cm Left
395 ws_prev
396 .It Cm M-a
397 ws_prior
398 .It Cm M-S- Ns Aq Cm Right
399 screen_next
400 .It Cm M-S- Ns Aq Cm Left
401 screen_prev
402 .It Cm M-s
403 screenshot_all
404 .It Cm M-S-s
405 screenshot_wind
406 .It Cm M-S-v
407 version
408 .It Cm M-t
409 float_toggle
410 .It Cm M-S- Ns Aq Cm Delete
411 lock
412 .It Cm M-S-i
413 initscr
414 .It Cm M-w
415 iconify
416 .It Cm M-S-w
417 uniconify
418 .It Cm M-S-r
419 always_raise
420 .It Cm M-v
421 button2
422 .It Cm M--
423 width_shrink
424 .It Cm M-=
425 width_grow
426 .It Cm M-S-
427 height_shrink
428 .It Cm M-S-=
429 height_grow
430 .It Cm M-[
431 move_left
432 .It Cm M-]
433 move_right
434 .It Cm M-S-[
435 move_up
436 .It Cm M-S-]
437 move_down
438 .El
439 .Pp
440 The action names and descriptions are listed below:
441 .Pp
442 .Bl -tag -width "M-j, M-<TAB>XXX" -offset indent -compact
443 .It Cm term
444 Spawn a new terminal
445 (see
446 .Sx PROGRAMS
447 above).
448 .It Cm menu
449 Menu
450 (see
451 .Sx PROGRAMS
452 above).
453 .It Cm quit
454 Quit
455 .Nm .
456 .It Cm restart
457 Restart
458 .Nm .
459 .It Cm cycle_layout
460 Cycle layout.
461 .It Cm reset_layout
462 Reset layout.
463 .It Cm master_shrink
464 Shrink master area.
465 .It Cm master_grow
466 Grow master area.
467 .It Cm master_add
468 Add windows to master area.
469 .It Cm master_del
470 Remove windows from master area.
471 .It Cm stack_inc
472 Add columns/rows to stacking area.
473 .It Cm stack_del
474 Remove columns/rows from stacking area.
475 .It Cm swap_main
476 Move current window to master area.
477 .It Cm focus_next
478 Focus next window in workspace.
479 .It Cm focus_prev
480 Focus previous window in workspace.
481 .It Cm focus_main
482 Focus on main window in workspace.
483 .It Cm swap_next
484 Swap with next window in workspace.
485 .It Cm swap_prev
486 Swap with previous window in workspace.
487 .It Cm bar_toggle
488 Toggle status bar in all workspaces.
489 .It Cm wind_del
490 Delete current window in workspace.
491 .It Cm wind_kill
492 Destroy current window in workspace.
493 .It Cm ws_ Ns Ar n
494 Switch to workspace
495 .Ar n ,
496 where
497 .Ar n
498 is 1 through 10.
499 .It Cm mvws_ Ns Ar n
500 Move current window to workspace
501 .Ar n ,
502 where
503 .Ar n
504 is 1 through 10.
505 .It Cm ws_next
506 Switch to next workspace with a window in it.
507 .It Cm ws_prev
508 Switch to previous workspace with a window in it.
509 .It Cm ws_prior
510 Switch to last visited workspace.
511 .It Cm screen_next
512 Move pointer to next region.
513 .It Cm screen_prev
514 Move pointer to previous region.
515 .It Cm screenshot_all
516 Take screenshot of entire screen (if enabled)
517 (see
518 .Sx PROGRAMS
519 above).
520 .It Cm screenshot_wind
521 Take screenshot of selected window (if enabled)
522 (see
523 .Sx PROGRAMS
524 above).
525 .It Cm version
526 Toggle version in status bar.
527 .It Cm float_toggle
528 Toggle focused window between tiled and floating.
529 .It Cm lock
530 Lock screen
531 (see
532 .Sx PROGRAMS
533 above).
534 .It Cm initscr
535 Reinitialize physical screens
536 (see
537 .Sx PROGRAMS
538 above).
539 .It Cm iconify
540 Minimize (unmap) currently focused window.
541 .It Cm uniconify
542 Maximize (map) window returned by dmenu selection.
543 .It Cm always_raise
544 When set tiled windows are allowed to obscure floating windows.
545 .It Cm button2
546 Fake a middle mouse button click (mouse button 2).
547 .It Cm width_shrink
548 Shrink the width of a floating window.
549 .It Cm width_grow
550 Grow the width of a floating window.
551 .It Cm height_shrink
552 Shrink the height of a floating window.
553 .It Cm height_grow
554 Grow the height of a floating window.
555 .It Cm move_left
556 Move a floating window a step to the left.
557 .It Cm move_right
558 Move a floating window a step to the right.
559 .It Cm move_up
560 Move a floating window a step upwards.
561 .It Cm move_down
562 Move a floating window a step downwards.
563 .El
564 .Pp
565 Custom bindings in the configuration file are specified as follows:
566 .Pp
567 .Dl bind[<action>] = <keys>
568 .Pp
569 .Aq action
570 is one of the actions listed above (or empty) and
571 .Aq keys
572 is in the form of zero or more modifier keys
573 (MOD, Mod1, Shift, etc.) and one or more normal keys
574 (b, space, etc.), separated by "+".
575 For example:
576 .Bd -literal -offset indent
577 bind[reset] = Mod4+q # bind Windows-key + q to reset
578 bind[] = Mod1+q # unbind Alt + q
579 .Ed
580 .Pp
581 Multiple key combinations may be bound to the same action.
582 .Sh QUIRKS
583 .Nm
584 provides "quirks" which handle windows that must be treated specially
585 in a tiling window manager, such as some dialogs and fullscreen apps.
586 .Pp
587 The default quirks are described below:
588 .Pp
589 .Bl -tag -width "OpenOffice.org N.M:VCLSalFrame<TAB>XXX" -offset indent -compact
590 .It Firefox\-bin:firefox\-bin
591 TRANSSZ
592 .It Firefox:Dialog
593 FLOAT
594 .It Gimp:gimp
595 FLOAT + ANYWHERE
596 .It MPlayer:xv
597 FLOAT + FULLSCREEN + FOCUSPREV
598 .It OpenOffice.org 2.4:VCLSalFrame
599 FLOAT
600 .It OpenOffice.org 3.1:VCLSalFrame
601 FLOAT
602 .It pcb:pcb
603 FLOAT
604 .It xine:Xine Window
605 FLOAT + ANYWHERE
606 .It xine:xine Panel
607 FLOAT + ANYWHERE
608 .It xine:xine Video Fullscreen Window
609 FULLSCREEN + FLOAT
610 .It Xitk:Xitk Combo
611 FLOAT + ANYWHERE
612 .It Xitk:Xine Window
613 FLOAT + ANYWHERE
614 .It XTerm:xterm
615 XTERM_FONTADJ
616 .El
617 .Pp
618 The quirks themselves are described below:
619 .Pp
620 .Bl -tag -width "XTERM_FONTADJ<TAB>XXX" -offset indent -compact
621 .It FLOAT
622 This window should not be tiled, but allowed to float freely.
623 .It TRANSSZ
624 Adjusts size on transient windows that are too small using dialog_ratio
625 (see
626 .Sx CONFIGURATION FILES ) .
627 .It ANYWHERE
628 Allow window to position itself, uncentered.
629 .It XTERM_FONTADJ
630 Adjust xterm fonts when resizing.
631 .It FULLSCREEN
632 Remove border to allow window to use full screen size.
633 .It FOCUSPREV
634 On exit force focus on previously focused application not previous application
635 in the stack.
636 .El
637 .Pp
638 Custom quirks in the configuration file are specified as follows:
639 .Pp
640 .Dl quirk[<class>:<name>] = <quirk> [ + <quirk> ... ]
641 .Pp
642 .Aq class
643 and
644 .Aq name
645 specify the window to which the quirk(s) apply, and
646 .Aq quirk
647 is one of the quirks from the list above.
648 For example:
649 .Bd -literal -offset indent
650 quirk[MPlayer:xv] = FLOAT + FULLSCREEN + FOCUSPREV
651 quirk[pcb:pcb] = NONE  # remove existing quirk
652 .Ed
653 .Pp
654 You can obtain
655 .Aq class
656 and
657 .Aq name
658 by running xprop(1) and then clicking on the desired window.
659 In the following example the main window of Firefox was clicked:
660 .Bd -literal -offset indent
661 $ xprop | grep WM_CLASS
662 WM_CLASS(STRING) = "Navigator", "Firefox"
663 .Ed
664 .Pp
665 Note that grepping for WM_CLASS flips class and name.
666 In the example above the quirk entry would be:
667 .Bd -literal -offset indent
668 quirk[Firefox:Navigator] = FLOAT
669 .Ed
670 .Pp
671 .Nm
672 also automatically assigns quirks to windows based on the value
673 of the window's _NET_WM_WINDOW_TYPE property as follows:
674 .Pp
675 .Bl -tag -width "_NET_WM_WINDOW_TYPE_TOOLBAR<TAB>XXX" -offset indent -compact
676 .It _NET_WM_WINDOW_TYPE_DOCK
677 FLOAT + ANYWHERE
678 .It _NET_WM_WINDOW_TYPE_TOOLBAR
679 FLOAT + ANYWHERE
680 .It _NET_WM_WINDOW_TYPE_UTILITY
681 FLOAT + ANYWHERE
682 .It _NET_WM_WINDOW_TYPE_SPLASH
683 FLOAT
684 .It _NET_WM_WINDOW_TYPE_DIALOG
685 FLOAT
686 .El
687 .Pp
688 In all other cases, no automatic quirks are assigned to the window.
689 Quirks specified in the configuration file override the automatic quirks.
690 .Sh EWMH
691 .Nm
692 partially implements the Extended Window Manager Hints (EWMH) specification.
693 This enables controlling windows as well as
694 .Nm
695 itself from external scripts and programs. This is achieved by
696 .Nm
697 responding to certain ClientMessage events. From the terminal these events
698 can be conveniently sent using tools such as
699 .Xr wmctrl 1
700 and
701 .Xr xdotool 1 .
702 For the
703 actual format of these ClientMessage events, see the EWMH specification.
704 .Pp
705 The id of the currently focused window is stored in the _NET_ACTIVE_WINDOW
706 property of the root window. This can be used for example to retrieve the
707 title of the currently active window with
708 .Xr xprop 1
709 and
710 .Xr grep 1 :
711 .Bd -literal -offset indent
712 $ WINDOWID=`xprop \-root _NET_ACTIVE_WINDOW | grep \-o "0x.*"`
713 $ xprop \-id $WINDOWID WM_NAME | grep \-o "\\".*\\""
714 .Ed
715 .Pp
716 A window can be focused by sending a _NET_ACTIVE_WINDOW client message
717 to the root window. For example, using
718 .Xr wmctrl 1
719 to send the message
720 (assuming 0x4a0000b is the id of the window to be focused):
721 .Bd -literal -offset indent
722 $ wmctrl \-i \-a 0x4a0000b
723 .Ed
724 .Pp
725 Windows can be closed by sending a _NET_CLOSE_WINDOW client message
726 to the root window. For example, using
727 .Xr wmctrl 1
728 to send the message
729 (assuming 0x4a0000b is the id of the window to be closed):
730 .Bd -literal -offset indent
731 $ wmctrl \-i \-c 0x4a0000b
732 .Ed
733 .Pp
734 Windows can be floated and un-floated by adding or removing the
735 _NET_WM_STATE_ABOVE atom from the _NET_WM_STATE property of the window.
736 This can be achieved by sending a _NET_WM_STATE client message to the
737 root window. For example, the following toggles the floating state of
738 a window using
739 .Xr wmctrl 1
740 to send the message (assuming 0x4a0000b is the  id of the window floated
741 or un-floated):
742 .Bd -literal -offset indent
743 $ wmctrl \-i \-r 0x4a0000b \-b toggle,_NET_WM_STATE_ABOVE
744 .Ed
745 .Pp
746 Floating windows can also be resized and moved by sending a
747 _NET_MOVERESIZE_WINDOW client message to the root window. For example,
748 using
749 .Xr wmctrl 1
750 to send the message (assuming 0x4a0000b is the id of
751 the window to be resize/moved):
752 .Bd -literal -offset indent
753 $ wmctrl \-i \-r 0x4a0000b \-e 0,100,50,640,480
754 .Ed
755 .Pp
756 This moves the window to (100,50) and resizes it to 640x480.
757 .Pp
758 Any _NET_MOVERESIZE_WINDOW events received for stacked windows are ignored.
759 .Sh SIGNALS
760 Sending
761 .Nm
762 a HUP signal will restart it.
763 .Sh FILES
764 .Bl -tag -width "/etc/scrotwm.confXXX" -compact
765 .It Pa ~/.scrotwm.conf
766 .Nm
767 user specific settings.
768 .It Pa /etc/scrotwm.conf
769 .Nm
770 global settings.
771 .El
772 .Sh HISTORY
773 .Nm
774 was inspired by xmonad & dwm.
775 .Sh AUTHORS
776 .An -nosplit
777 .Nm
778 was written by:
779 .Pp
780 .Bl -tag -width "Ryan Thomas McBride Aq mcbride@countersiege.com " -offset indent -compact
781 .It Cm Marco Peereboom Aq marco@peereboom.us
782 .It Cm Ryan Thomas McBride Aq mcbride@countersiege.com
783 .It Cm Darrin Chandler Aq dwchandler@stilyagin.com
784 .It Cm Pierre-Yves Ritschard Aq pyr@spootnik.org
785 .It Cm Tuukka Kataja Aq stuge@xor.fi
786 .It Cm Jason L. Wright Aq jason@thought.net
787 .El
788 .Sh BUGS
789 Currently the menu, invoked with
790 .Cm M-p ,
791 depends on dmenu.