Compare commits
78 Commits
Author | SHA1 | Date | |
---|---|---|---|
1380569133 | |||
831428b00c | |||
69439715c0 | |||
f2e98f48fb | |||
c19d4b2930 | |||
f77a3d0a62 | |||
8aa1533879 | |||
2fc9cffdeb | |||
3c5b6f03ba | |||
02673538bc | |||
95eae7b9d2 | |||
59107755c8 | |||
d05d09b205 | |||
47b1974446 | |||
247ba66c08 | |||
d7b074fcce | |||
c9170189bf | |||
f7a45ff28b | |||
add7df6e9b | |||
3a79b82721 | |||
b31b430592 | |||
88c8ead3e8 | |||
2e95837220 | |||
5d9ae3f3b7 | |||
2e38296edd | |||
59aa02a075 | |||
e3c2d327f6 | |||
295ad21092 | |||
39af3c2607 | |||
96ee9d888c | |||
a82cba2759 | |||
f7c097e802 | |||
da1b3fa437 | |||
ad0a2fa042 | |||
9804726c82 | |||
7bc272a4e4 | |||
f1719ac2de | |||
d99ec61482 | |||
2f70a14ee1 | |||
00ca643bd7 | |||
0271ac0ed7 | |||
d5178292ed | |||
2bfd3fffbf | |||
a3d8c05a95 | |||
fd01413fae | |||
d6e24f7116 | |||
c43d7b7587 | |||
de5b294edc | |||
8e0f8ffcc6 | |||
dd21823536 | |||
9cb9c32ee7 | |||
4076e2ff60 | |||
55edd2d6ec | |||
2e8e5509d9 | |||
4426032450 | |||
e0f0397896 | |||
ca3e847e45 | |||
c2737b7b93 | |||
191cb9ce28 | |||
6ab163c695 | |||
e8244395e4 | |||
954db46bac | |||
508922b90d | |||
4adfdc9d95 | |||
c619363d15 | |||
012710a3ce | |||
c2c54cc0fa | |||
a62630ae92 | |||
62b18fb9d4 | |||
e0d6451086 | |||
7a496e9777 | |||
308f95ae5a | |||
40a734bca9 | |||
985e330524 | |||
5f19423c7b | |||
d66ad1457e | |||
8497f9f781 | |||
91bb749e97 |
1
.hgtags
1
.hgtags
@ -50,3 +50,4 @@ e0ec0d5d8b1ef3ee04a83c7c0fee5853aa2ac6a6 4.3
|
||||
7c117df5d202530e85066d8b1ab02cef605c79ad 4.4.1
|
||||
2acc60d6dfe28c101a8cd44a8aa710a38ae3607c 4.5
|
||||
bcd7e18e196a00cc2e97ff3a4a58f3cdaba13856 4.6
|
||||
d6d3085307d8d98b8b012b669e858fd787befeb1 4.7
|
||||
|
4
LICENSE
4
LICENSE
@ -1,10 +1,12 @@
|
||||
MIT/X Consortium License
|
||||
|
||||
© 2006-2007 Anselm R. Garbe <garbeam at gmail dot com>
|
||||
© 2006-2008 Anselm R Garbe <garbeam at gmail dot com>
|
||||
© 2006-2007 Sander van Dijk <a dot h dot vandijk at gmail dot com>
|
||||
© 2006-2007 Jukka Salmi <jukka at salmi dot ch>
|
||||
© 2007 Premysl Hruby <dfenze at gmail dot com>
|
||||
© 2007 Szabolcs Nagy <nszabolcs at gmail dot com>
|
||||
© 2007 Christof Musik <christof at sendfax dot de>
|
||||
© 2007-2008 Enno Gottox Boland <gottox at s01 dot de>
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a
|
||||
copy of this software and associated documentation files (the "Software"),
|
||||
|
2
Makefile
2
Makefile
@ -35,7 +35,7 @@ clean:
|
||||
dist: clean
|
||||
@echo creating dist tarball
|
||||
@mkdir -p dwm-${VERSION}
|
||||
@cp -R LICENSE Makefile README config.def.h config.mk \
|
||||
@cp -R LICENSE Makefile README config.*.h config.mk \
|
||||
dwm.1 ${SRC} dwm-${VERSION}
|
||||
@tar -cf dwm-${VERSION}.tar dwm-${VERSION}
|
||||
@gzip dwm-${VERSION}.tar
|
||||
|
151
config.anselm.h
Normal file
151
config.anselm.h
Normal file
@ -0,0 +1,151 @@
|
||||
/* See LICENSE file for copyright and license details. */
|
||||
|
||||
/* appearance */
|
||||
#define BORDERPX 1
|
||||
#define FONT "-*-terminus-medium-r-normal-*-14-*-*-*-*-*-*-*"
|
||||
#define NORMBORDERCOLOR "#cccccc"
|
||||
#define NORMBGCOLOR "#cccccc"
|
||||
#define NORMFGCOLOR "#000000"
|
||||
#define SELBORDERCOLOR "#0066ff"
|
||||
#define SELBGCOLOR "#0066ff"
|
||||
#define SELFGCOLOR "#ffffff"
|
||||
|
||||
/* tagging */
|
||||
const char tags[][MAXTAGLEN] = { "1", "2", "3", "4", "5", "6", "7", "8", "9" };
|
||||
|
||||
Rule rules[] = {
|
||||
/* class:instance:title substr tags ref isfloating */
|
||||
{ "Firefox", tags[8], False },
|
||||
{ "Gimp", NULL, True },
|
||||
{ "MPlayer", NULL, True },
|
||||
{ "Acroread", NULL, True },
|
||||
};
|
||||
|
||||
/* layout(s) */
|
||||
#define RESIZEHINTS True /* False - respect size hints in tiled resizals */
|
||||
#define SNAP 32 /* snap pixel */
|
||||
|
||||
Layout layouts[] = {
|
||||
/* symbol function isfloating */
|
||||
{ "[]|", tileh, False }, /* first entry is default */
|
||||
{ "[]=", tilev, False },
|
||||
{ "><>", floating, True },
|
||||
{ "[M]", monocle, True },
|
||||
};
|
||||
|
||||
void
|
||||
setanselmgeoms(void) {
|
||||
|
||||
/* screen dimensions */
|
||||
sx = 0;
|
||||
sy = 0;
|
||||
sw = DisplayWidth(dpy, screen);
|
||||
sh = DisplayHeight(dpy, screen);
|
||||
|
||||
/* bar position */
|
||||
bx = sx;
|
||||
by = sy;
|
||||
bw = 1280;
|
||||
bh = dc.font.height + 2;
|
||||
|
||||
/* window area */
|
||||
wx = sx;
|
||||
wy = sy + bh;
|
||||
ww = sw;
|
||||
wh = sh - bh;
|
||||
|
||||
/* master area */
|
||||
mx = wx;
|
||||
my = wy;
|
||||
mw = 1280;
|
||||
mh = 800 - bh;
|
||||
|
||||
/* tile area */
|
||||
tx = 1280;
|
||||
ty = 0;
|
||||
tw = sw - 1280;
|
||||
th = sh;
|
||||
|
||||
/* monocle area */
|
||||
mox = mx;
|
||||
moy = my;
|
||||
mow = mw;
|
||||
moh = mh;
|
||||
}
|
||||
|
||||
void
|
||||
anselmgeoms(const char *arg) {
|
||||
setgeoms = setanselmgeoms;
|
||||
setgeoms();
|
||||
updatebarpos();
|
||||
setlayout("[]|");
|
||||
}
|
||||
|
||||
void
|
||||
defgeoms(const char *arg) {
|
||||
setgeoms = setdefaultgeoms;
|
||||
setgeoms();
|
||||
updatebarpos();
|
||||
setlayout("[]=");
|
||||
}
|
||||
|
||||
/* key definitions */
|
||||
#define MODKEY Mod1Mask
|
||||
Key keys[] = {
|
||||
/* modifier key function argument */
|
||||
{ MODKEY, XK_p, spawn,
|
||||
"exec dmenu_run -fn '"FONT"' -nb '"NORMBGCOLOR"' -nf '"NORMFGCOLOR"' -sb '"SELBGCOLOR"' -sf '"SELFGCOLOR"' -x 0 -y 0 -w 1280" },
|
||||
{ MODKEY|ShiftMask, XK_Return, spawn, "exec uxterm" },
|
||||
{ MODKEY, XK_a, anselmgeoms, NULL },
|
||||
{ MODKEY, XK_d, defgeoms, NULL },
|
||||
{ MODKEY, XK_j, focusnext, NULL },
|
||||
{ MODKEY, XK_k, focusprev, NULL },
|
||||
{ MODKEY, XK_r, reapply, NULL },
|
||||
{ MODKEY, XK_Return, zoom, NULL },
|
||||
{ MODKEY, XK_Tab, viewprevtag, NULL },
|
||||
{ MODKEY, XK_m, setlayout, "[M]" },
|
||||
{ MODKEY, XK_f, setlayout, "><>" },
|
||||
{ MODKEY, XK_v, setlayout, "[]=" },
|
||||
{ MODKEY, XK_h, setlayout, "[]|" },
|
||||
{ MODKEY|ShiftMask, XK_space, togglefloating, NULL },
|
||||
{ MODKEY|ShiftMask, XK_c, killclient, NULL },
|
||||
{ MODKEY, XK_0, view, NULL },
|
||||
{ MODKEY, XK_1, view, tags[0] },
|
||||
{ MODKEY, XK_2, view, tags[1] },
|
||||
{ MODKEY, XK_3, view, tags[2] },
|
||||
{ MODKEY, XK_4, view, tags[3] },
|
||||
{ MODKEY, XK_5, view, tags[4] },
|
||||
{ MODKEY, XK_6, view, tags[5] },
|
||||
{ MODKEY, XK_7, view, tags[6] },
|
||||
{ MODKEY, XK_8, view, tags[7] },
|
||||
{ MODKEY, XK_9, view, tags[8] },
|
||||
{ MODKEY|ControlMask, XK_1, toggleview, tags[0] },
|
||||
{ MODKEY|ControlMask, XK_2, toggleview, tags[1] },
|
||||
{ MODKEY|ControlMask, XK_3, toggleview, tags[2] },
|
||||
{ MODKEY|ControlMask, XK_4, toggleview, tags[3] },
|
||||
{ MODKEY|ControlMask, XK_5, toggleview, tags[4] },
|
||||
{ MODKEY|ControlMask, XK_6, toggleview, tags[5] },
|
||||
{ MODKEY|ControlMask, XK_7, toggleview, tags[6] },
|
||||
{ MODKEY|ControlMask, XK_8, toggleview, tags[7] },
|
||||
{ MODKEY|ControlMask, XK_9, toggleview, tags[8] },
|
||||
{ MODKEY|ShiftMask, XK_0, tag, NULL },
|
||||
{ MODKEY|ShiftMask, XK_1, tag, tags[0] },
|
||||
{ MODKEY|ShiftMask, XK_2, tag, tags[1] },
|
||||
{ MODKEY|ShiftMask, XK_3, tag, tags[2] },
|
||||
{ MODKEY|ShiftMask, XK_4, tag, tags[3] },
|
||||
{ MODKEY|ShiftMask, XK_5, tag, tags[4] },
|
||||
{ MODKEY|ShiftMask, XK_6, tag, tags[5] },
|
||||
{ MODKEY|ShiftMask, XK_7, tag, tags[6] },
|
||||
{ MODKEY|ShiftMask, XK_8, tag, tags[7] },
|
||||
{ MODKEY|ShiftMask, XK_9, tag, tags[8] },
|
||||
{ MODKEY|ControlMask|ShiftMask, XK_1, toggletag, tags[0] },
|
||||
{ MODKEY|ControlMask|ShiftMask, XK_2, toggletag, tags[1] },
|
||||
{ MODKEY|ControlMask|ShiftMask, XK_3, toggletag, tags[2] },
|
||||
{ MODKEY|ControlMask|ShiftMask, XK_4, toggletag, tags[3] },
|
||||
{ MODKEY|ControlMask|ShiftMask, XK_5, toggletag, tags[4] },
|
||||
{ MODKEY|ControlMask|ShiftMask, XK_6, toggletag, tags[5] },
|
||||
{ MODKEY|ControlMask|ShiftMask, XK_7, toggletag, tags[6] },
|
||||
{ MODKEY|ControlMask|ShiftMask, XK_8, toggletag, tags[7] },
|
||||
{ MODKEY|ControlMask|ShiftMask, XK_9, toggletag, tags[8] },
|
||||
{ MODKEY|ShiftMask, XK_q, quit, NULL },
|
||||
};
|
34
config.def.h
34
config.def.h
@ -1,9 +1,8 @@
|
||||
/* See LICENSE file for copyright and license details. */
|
||||
|
||||
/* appearance */
|
||||
#define BARPOS BarTop /* BarBot, BarOff */
|
||||
#define BORDERPX 1
|
||||
#define FONT "-*-terminus-medium-*-*-*-*-*-*-*-*-*-*-*"
|
||||
#define FONT "-*-terminus-medium-r-normal-*-14-*-*-*-*-*-*-*"
|
||||
#define NORMBORDERCOLOR "#cccccc"
|
||||
#define NORMBGCOLOR "#cccccc"
|
||||
#define NORMFGCOLOR "#000000"
|
||||
@ -12,24 +11,26 @@
|
||||
#define SELFGCOLOR "#ffffff"
|
||||
|
||||
/* tagging */
|
||||
const char tags[][MAXTAGLEN] = { "1", "2", "3", "4", "5", "6", "7", "8", "www" };
|
||||
Bool seltags[LENGTH(tags)] = {[0] = True};
|
||||
const char tags[][MAXTAGLEN] = { "1", "2", "3", "4", "5", "6", "7", "8", "9" };
|
||||
|
||||
Rule rules[] = {
|
||||
/* class:instance:title regex tags regex isfloating */
|
||||
{ "Firefox", "www", False },
|
||||
/* class:instance:title substr tags ref isfloating */
|
||||
{ "Firefox", tags[8], False },
|
||||
{ "Gimp", NULL, True },
|
||||
{ "MPlayer", NULL, True },
|
||||
{ "Acroread", NULL, True },
|
||||
};
|
||||
|
||||
/* layout(s) */
|
||||
#define MWFACT 0.6 /* master width factor [0.1 .. 0.9] */
|
||||
#define RESIZEHINTS True /* False - respect size hints in tiled resizals */
|
||||
#define SNAP 32 /* snap pixel */
|
||||
|
||||
Layout layouts[] = {
|
||||
/* symbol function */
|
||||
{ "[]=", tile }, /* first entry is default */
|
||||
{ "><>", floating },
|
||||
/* symbol function isfloating */
|
||||
{ "[]=", tilev, False }, /* first entry is default */
|
||||
{ "[]|", tileh, False },
|
||||
{ "><>", floating, True },
|
||||
{ "[M]", monocle, True },
|
||||
};
|
||||
|
||||
/* key definitions */
|
||||
@ -37,18 +38,17 @@ Layout layouts[] = {
|
||||
Key keys[] = {
|
||||
/* modifier key function argument */
|
||||
{ MODKEY, XK_p, spawn,
|
||||
"exe=`dmenu_path | dmenu -fn '"FONT"' -nb '"NORMBGCOLOR"' -nf '"NORMFGCOLOR"'"
|
||||
" -sb '"SELBGCOLOR"' -sf '"SELFGCOLOR"'` && exec $exe" },
|
||||
"exec dmenu_run -fn '"FONT"' -nb '"NORMBGCOLOR"' -nf '"NORMFGCOLOR"' -sb '"SELBGCOLOR"' -sf '"SELFGCOLOR"'" },
|
||||
{ MODKEY|ShiftMask, XK_Return, spawn, "exec uxterm" },
|
||||
{ MODKEY, XK_space, setlayout, NULL },
|
||||
{ MODKEY, XK_b, togglebar, NULL },
|
||||
{ MODKEY, XK_j, focusnext, NULL },
|
||||
{ MODKEY, XK_k, focusprev, NULL },
|
||||
{ MODKEY, XK_h, setmwfact, "-0.05" },
|
||||
{ MODKEY, XK_l, setmwfact, "+0.05" },
|
||||
{ MODKEY, XK_m, togglemax, NULL },
|
||||
{ MODKEY, XK_r, reapply, NULL },
|
||||
{ MODKEY, XK_Return, zoom, NULL },
|
||||
{ MODKEY, XK_Tab, viewprevtag, NULL },
|
||||
{ MODKEY, XK_m, setlayout, "[M]" },
|
||||
{ MODKEY, XK_f, setlayout, "><>" },
|
||||
{ MODKEY, XK_v, setlayout, "[]=" },
|
||||
{ MODKEY, XK_h, setlayout, "[]|" },
|
||||
{ MODKEY|ShiftMask, XK_space, togglefloating, NULL },
|
||||
{ MODKEY|ShiftMask, XK_c, killclient, NULL },
|
||||
{ MODKEY, XK_0, view, NULL },
|
||||
|
@ -1,5 +1,5 @@
|
||||
# dwm version
|
||||
VERSION = 4.7
|
||||
VERSION = 4.8
|
||||
|
||||
# Customize below to fit your system
|
||||
|
||||
@ -17,7 +17,7 @@ LIBS = -L/usr/lib -lc -L${X11LIB} -lX11
|
||||
# flags
|
||||
CFLAGS = -Os ${INCS} -DVERSION=\"${VERSION}\"
|
||||
LDFLAGS = -s ${LIBS}
|
||||
#CFLAGS = -g -std=c99 -pedantic -Wall -O2 ${INCS} -DVERSION=\"${VERSION}\"
|
||||
#CFLAGS = -g -std=c99 -pedantic -Wall -O2 ${INCS} -DVERSION=\"${VERSION}\" -DWORK
|
||||
#LDFLAGS = -g ${LIBS}
|
||||
|
||||
# Solaris
|
||||
|
79
dwm.1
79
dwm.1
@ -5,22 +5,23 @@ dwm \- dynamic window manager
|
||||
.B dwm
|
||||
.RB [ \-v ]
|
||||
.SH DESCRIPTION
|
||||
dwm is a dynamic window manager for X. It manages windows in tiled and
|
||||
floating layouts. Either layout can be applied dynamically, optimizing the
|
||||
dwm is a dynamic window manager for X. It manages windows in tiled, monocle
|
||||
and floating layouts. Either layout can be applied dynamically, optimising the
|
||||
environment for the application in use and the task performed.
|
||||
.P
|
||||
In tiled layout windows are managed in a master and stacking area. The master
|
||||
In tiled layouts windows are managed in a master and stacking area. The master
|
||||
area contains the window which currently needs most attention, whereas the
|
||||
stacking area contains all other windows. In floating layout windows can be
|
||||
resized and moved freely. Dialog windows are always managed floating,
|
||||
regardless of the layout applied.
|
||||
stacking area contains all other windows. In monocle layout all windows are
|
||||
maximised to the screen size. In floating layout windows can be resized and
|
||||
moved freely. Dialog windows are always managed floating, regardless of the
|
||||
layout applied.
|
||||
.P
|
||||
Windows are grouped by tags. Each window can be tagged with one or multiple
|
||||
tags. Selecting certain tags displays all windows with these tags.
|
||||
.P
|
||||
dwm contains a small status bar which displays all available tags, the layout,
|
||||
the title of the focused window, and the text read from standard input. A
|
||||
floating window is indicated with an empty square and a maximized
|
||||
floating window is indicated with an empty square and a maximised
|
||||
floating window is indicated with a filled square before the windows
|
||||
title. The selected tags are indicated with a different color. The tags of
|
||||
the focused window are indicated with a filled square in the top left
|
||||
@ -56,17 +57,17 @@ click on a tag label adds/removes that tag to/from the focused window.
|
||||
Start
|
||||
.BR xterm.
|
||||
.TP
|
||||
.B Mod1\-Return
|
||||
Zooms/cycles current window to/from master area (tiled layout only).
|
||||
.B Mod1\-f
|
||||
Applies floating layout.
|
||||
.TP
|
||||
.B Mod1\-Tab
|
||||
Toggles to the previously selected tags.
|
||||
.B Mod1\-m
|
||||
Applies monocle layout.
|
||||
.TP
|
||||
.B Mod1\-b
|
||||
Shows/hides the status bar.
|
||||
.B Mod1\-v
|
||||
Applies vertical tiled layout.
|
||||
.TP
|
||||
.B Mod1\-h
|
||||
Decreases the master area width about 5% (tiled layout only).
|
||||
Applies horizontal tiled layout.
|
||||
.TP
|
||||
.B Mod1\-j
|
||||
Focus next window.
|
||||
@ -74,34 +75,34 @@ Focus next window.
|
||||
.B Mod1\-k
|
||||
Focus previous window.
|
||||
.TP
|
||||
.B Mod1\-l
|
||||
Increases the master area width about 5% (tiled layout only).
|
||||
.TP
|
||||
.B Mod1\-m
|
||||
Toggles maximization of current window.
|
||||
.TP
|
||||
.B Mod1\-Shift\-[1..n]
|
||||
Apply
|
||||
.RB nth
|
||||
tag to current window.
|
||||
.TP
|
||||
.B Mod1\-Shift\-0
|
||||
Apply all tags to current window.
|
||||
.TP
|
||||
.B Mod1\-Control\-Shift\-[1..n]
|
||||
Add/remove
|
||||
.B nth
|
||||
tag to/from current window.
|
||||
.B Mod1\-Return
|
||||
Zooms/cycles focused window to/from master area (tiled layouts only).
|
||||
.TP
|
||||
.B Mod1\-Shift\-c
|
||||
Close focused window.
|
||||
.TP
|
||||
.B Mod1\-space
|
||||
Toggle between tiled and floating layout (affects all windows).
|
||||
.TP
|
||||
.B Mod1\-Shift\-space
|
||||
Toggle focused window between tiled and floating state.
|
||||
.TP
|
||||
.B Mod1\-Tab
|
||||
Toggles to the previously selected tags.
|
||||
.TP
|
||||
.B Mod1\-r
|
||||
Re-applies tagging rules to all windows.
|
||||
.TP
|
||||
.B Mod1\-Shift\-[1..n]
|
||||
Apply
|
||||
.RB nth
|
||||
tag to focused window.
|
||||
.TP
|
||||
.B Mod1\-Shift\-0
|
||||
Apply all tags to focused window.
|
||||
.TP
|
||||
.B Mod1\-Control\-Shift\-[1..n]
|
||||
Add/remove
|
||||
.B nth
|
||||
tag to/from focused window.
|
||||
.TP
|
||||
.B Mod1\-[1..n]
|
||||
View all windows with
|
||||
.BR nth
|
||||
@ -120,13 +121,13 @@ Quit dwm.
|
||||
.SS Mouse commands
|
||||
.TP
|
||||
.B Mod1\-Button1
|
||||
Move current window while dragging. Tiled windows will be toggled to the floating state.
|
||||
Move focused window while dragging. Tiled windows will be toggled to the floating state.
|
||||
.TP
|
||||
.B Mod1\-Button2
|
||||
Zooms/cycles current window to/from master area. If it is floating (but not fixed) it will be toggled to the tiled state instead.
|
||||
Zooms/cycles focused window to/from master area. If it is floating (but not fixed) it will be toggled to the tiled state instead.
|
||||
.TP
|
||||
.B Mod1\-Button3
|
||||
Resize current window while dragging. Tiled windows will be toggled to the floating state.
|
||||
Resize focused window while dragging. Tiled windows will be toggled to the floating state.
|
||||
.SH CUSTOMIZATION
|
||||
dwm is customized by creating a custom config.h and (re)compiling the source
|
||||
code. This keeps it fast, secure and simple.
|
||||
@ -147,7 +148,7 @@ can set the following environment variable (to use the older Motif
|
||||
backend instead):
|
||||
.BR AWT_TOOLKIT=MToolkit .
|
||||
.P
|
||||
Recent GTK 2.10.9+ versions contain a broken
|
||||
GTK 2.10.9+ versions contain a broken
|
||||
.BR Save\-As
|
||||
file dialog implementation,
|
||||
which requests to reconfigure its window size in an endless loop. However, its
|
||||
|
Reference in New Issue
Block a user