cwm(1)

cwm1

A lightweight and efficient window manager for x11

Usage

cwm [-nv] [-c file] [-d display]

Overview

cwm is a window manager for X11 which contains many features that concentrate on the efficiency and transparency of window management, while maintaining the simplest and most pleasant aesthetic.

The options are as follows:

-c file

Specify an alternative configuration file. By default, cwm loads ~/.cwmrc, if present. Any error messages from lines in the configuration file will be sent to stderr; however, cwm will continue to process the rest of the configuration file.

-d display

Specify the display to use.

-n

Configtest mode. Only check the configuration file for validity.

-v

Verbose mode. Multiple -v options increase the verbosity.

cwm actions are initiated either via key or mouse bindings. The following notations are used throughout this page:

C

Control key.

M

Meta key.

S

Shift key.

4

Mod4 (windows) key.

M1

Left mouse button.

M2

Middle mouse button.

M3

Right mouse button.

The default key bindings are:

CM-Return

Spawn a new terminal.

CM-Delete

Lock the screen.

M-Return

Hide current window.

M-Down

Lower current window.

M-Up

Raise current window.

M-slash

Search for windows.

C-slash

Search for applications.

CM-n

Label current window.

M-Tab

Cycle through currently visible windows.

MS-Tab

Reverse cycle through currently visible windows.

CM-x

Close current window.

CM-[n]

Toggle visibility of group n, where n is 1–9.

CM-a

Toggle visibility of all groups.

CM-g

Toggle group membership of current window.

M-Right

Cycle through active groups.

M-Left

Reverse cycle through active groups.

CMS-f

Toggle freezing geometry of current window.

CM-s

Toggle stickiness of current window.

CM-f

Toggle full-screen mode of current window.

CM-m

Toggle maximization of current window.

CM-equal

Toggle vertical maximization of current window.

CMS-equal

Toggle horizontal maximization of current window.

M-[hjkl]

Move window by a small amount.

MS-[hjkl]

Move window by a large amount; see cwmrc(5).

CM-[hjkl]

Resize window by a small amount.

CMS-[hjkl]

Resize window by a large amount; see cwmrc(5).

M-question

Spawn “exec program” dialog.

M-period

Spawn “ssh to” dialog. This parses $HOME/.ssh/known_hosts to provide host auto-completion. ssh(1) will be executed via the configured terminal emulator.

CM-w

Spawn “exec WindowManager” menu, allowing a switch to another window manager.

CMS-r

Restart.

CMS-q

Quit.

The default mouse bindings are:

M-M1

Move current window.

CM-M1

Toggle group membership of current window.

M-M2

Resize current window

M-M3

Lower current window.

CMS-M3

Hide current window.

The following key bindings may be used to navigate search and exec dialogs:

[Return]

Select item.

[Down], C-s or M-j

Next item.

[Up], C-r or M-k

Previous item.

[Backspace] or C-h

Backspace.

C-u

Clear input.

C-a

List all available items.

[Esc]

Cancel.

cwm rereads its configuration file when it receives a hangup signal, SIGHUP, by executing itself with the name and arguments with which it was started. This is equivalent to the restart function.

Applications

cwm manages a list of applications defined with the command configuration option.

Groups

cwm has the ability to group windows together, and use the groups to perform operations on the entire group instead of just one window. Together with the sticky option, this can be used to emulate virtual desktops.

To edit groups, use the group selection commands to toggle membership of a group. A blue border will be shown briefly on windows added to the current group, and a red border will be shown on those just removed.

Environment

DISPLAY

cwm starts on this display unless the -d option is given.

Files

~/.cwmrc

Default cwm configuration file.

Releases

5 releases since Debian 6.0 (Squeeze); the text changed 2 times.

  1. 6.0
  2. 9–10
  3. 12–13

-c since Debian 12 (Bookworm); -d since Debian 12 (Bookworm); -n since Debian 12 (Bookworm); -v since Debian 12 (Bookworm).

--apply until Debian 10 (Buster); --base until Debian 10 (Buster); --bySubject until Debian 10 (Buster); --chatty until Debian 10 (Buster); --closure until Debian 10 (Buster); --crypto until Debian 10 (Buster); --data until Debian 10 (Buster); --dereify until Debian 10 (Buster); --engine until Debian 10 (Buster); --filter until Debian 10 (Buster); --flatten until Debian 10 (Buster); --help until Debian 10 (Buster); --language until Debian 10 (Buster); --languageOptions until Debian 10 (Buster); --mode until Debian 10 (Buster); --n3 until Debian 10 (Buster); --no until Debian 10 (Buster); --ntriples until Debian 10 (Buster); --patch until Debian 10 (Buster); --pipe until Debian 10 (Buster); --purge until Debian 10 (Buster); --query until Debian 10 (Buster); --rdf until Debian 10 (Buster); --reify until Debian 10 (Buster); --revision until Debian 10 (Buster); --rules until Debian 10 (Buster); --sparql until Debian 10 (Buster); --sparqlResults until Debian 10 (Buster); --sparqlServer until Debian 10 (Buster); --strings until Debian 10 (Buster); --think until Debian 10 (Buster); --ugly until Debian 10 (Buster); --unflatten until Debian 10 (Buster); --why until Debian 10 (Buster); --with until Debian 10 (Buster).

History

cwm was originally inspired by evilwm, but was rewritten from scratch due to limitations in the evilwm codebase. The from-scratch rewrite borrowed some code from 9wm, however that code has since been removed or rewritten.

cwm first appeared in OpenBSD 4.2.

Authors

cwm was developed by Marius Aamodt Eriksen ⟨[email protected]⟩ with contributions from Andy Adamson ⟨[email protected]⟩, Niels Provos ⟨[email protected]⟩, and Antti Nykänen ⟨[email protected]⟩. Ideas, discussion with many others.

From cwm 7.1-1 in Debian 13 (Trixie). Parsed by carta from the page's mdoc source.