-
Notifications
You must be signed in to change notification settings - Fork 13
/
wm-init-sample.scm
81 lines (63 loc) · 2.57 KB
/
wm-init-sample.scm
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
;; -*- scheme -*-
;; This file is part of Guile-WM.
;; Guile-WM is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; Guile-WM is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with Guile-WM. If not, see <http://www.gnu.org/licenses/>.
;;; Sample user init file for Guile-WM
;; You can include built-in modules using this shorthand syntax. Each
;; line that contains a comment and the prefix "wm-modules:" will be
;; read as a list of modules to load from (guile-wm module ...)
;; wm-modules: cursor root-keymap
;; wm-modules: minibuffer repl randr fullscreen
;; wm-modules: menu message window-menu time simple-reparent
;; wm-modules: simple-focus window-cycle tinywm
;; Command helpers
(define-command (emacs) (shell-command "emacsclient -c"))
(define-command (conkeror) (shell-command "conkeror"))
;; Multi-monitor setup.
(set-resolution! "VGA-0" 1680 1050)
(set-resolution! "DVI-0" 1920 1200)
(set-offset! "DVI-0" 1680 0)
;; Root key binding (I use xmodmap to map super key to F20. Maybe that
;; should be built into this as well.)
;; Default root key is C-t
(set! (root-key) 'F20)
;; simple-focus simply draws a thin border around the focused window
;; Color of window border when focused/unfocused
(set! (simple-focus-color) 'light-steel-blue)
(set! (simple-unfocus-color) 'black)
;; Set the cursor and the keymap cursor
(set-cursor! 'x-cursor)
(set! (keymap-cursor) 'draped-box)
;; Set fonts
(let ((proggy "-*-proggyclean-*-*-*-*-*-*-*-*-*-70-*-*"))
(set! minibuffer-font proggy)
(set! menu-font proggy)
(set! message-font proggy))
;; Start repl server on the default port
(start-wm-repl)
;; Root keymap
(bind-key-commands root-keymap prompt-for-additional-arg
(semicolon "prompt-for-command")
(colon "prompt-for-eval")
(bang "prompt-for-shell-command")
(C-q "quit")
(f "conkeror")
(F "fullscreen")
(e "emacs")
(w "select-window")
(T "show-time")
(n "window-cycle")
(tab "visible-window-cycle")
(c "shell-command xterm -e telnet localhost 37146")
(t "shell-command xterm"))
;; Startup programs
(shell-command "emacs --daemon")
(shell-command (format #f "xterm -e 'tail /tmp/guile-wm.log -f'"))