1 ;;; --------------------------------------------------------------------------
2 ;;; CLFSWM - FullScreen Window Manager
4 ;;; --------------------------------------------------------------------------
5 ;;; Documentation: Configuration file
7 ;;; Change this file to your own needs or update some of this variables in
9 ;;; Some simple hack can be done in the code begining with the word CONFIG
10 ;;; (you can do a 'grep CONFIG *.lisp' to see what you can configure)
11 ;;; --------------------------------------------------------------------------
13 ;;; (C) 2011 Philippe Brochard <hocwp@free.fr>
15 ;;; This program is free software; you can redistribute it and/or modify
16 ;;; it under the terms of the GNU General Public License as published by
17 ;;; the Free Software Foundation; either version 3 of the License, or
18 ;;; (at your option) any later version.
20 ;;; This program is distributed in the hope that it will be useful,
21 ;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
22 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23 ;;; GNU General Public License for more details.
25 ;;; You should have received a copy of the GNU General Public License
26 ;;; along with this program; if not, write to the Free Software
27 ;;; Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
29 ;;; --------------------------------------------------------------------------
34 ;;; CONFIG - Default modifiers
35 (defconfig *default-modifiers
* '() nil
36 "Default modifiers list to append to explicit modifiers
37 Example: :mod-2 for num_lock, :lock for Caps_lock...")
40 (defun-equal-wm-class equal-wm-class-rox-pinboard
"ROX-Pinboard")
41 (defun-equal-wm-class equal-wm-class-xvkbd
"xvkbd")
43 ;;; CONFIG - Never managed window list
44 (defconfig *never-managed-window-list
*
45 (list (list 'equal-wm-class-rox-pinboard nil
)
46 (list 'equal-wm-class-xvkbd
'raise-window
)
47 (list 'equal-clfswm-terminal
'raise-and-focus-window
))
48 nil
"CLFSWM will never manage windows of this type.
49 A list of (list match-function handle-function)")
53 (defconfig *hide-unmanaged-window
* t nil
54 "Hide or not unmanaged windows when a child is deselected.")
56 (defconfig *snap-size
* 20 nil
57 "Snap size (in pixels) when move or resize frame is constrained")
59 (defconfig *spatial-move-delay-before
* 0.2 nil
60 "Delay to display the current child before doing a spatial move")
62 (defconfig *spatial-move-delay-after
* 0.5 nil
63 "Delay to display the new child after doing a spatial move")
66 ;;; CONFIG - Screen size
67 (defun get-fullscreen-size ()
68 "Return the size of root child (values rx ry rw rh)
69 You can tweak this to what you want"
70 (values (- *border-size
*) (- *border-size
*)
71 (xlib:screen-width
*screen
*)
72 (xlib:screen-height
*screen
*)))
73 ;;(values -1 -1 (xlib:screen-width *screen*) (xlib:screen-height *screen*)))
74 ;; (values -1 -1 1024 768))
75 ;; (values 100 100 800 600))
78 (defconfig *corner-size
* 3 'Corner
79 "The size of the corner square")
81 ;;; CONFIG: Corner actions - See in clfswm-corner.lisp for
83 (defconfig *corner-main-mode-left-button
*
84 '((:top-left open-menu
)
85 (:top-right present-virtual-keyboard
)
86 (:bottom-right expose-windows-mode
)
88 'Corner
"Actions on corners in the main mode with the left mouse button")
90 (defconfig *corner-main-mode-middle-button
*
91 '((:top-left help-on-clfswm
)
92 (:top-right ask-close
/kill-current-window
)
95 'Corner
"Actions on corners in the main mode with the middle mouse button")
97 (defconfig *corner-main-mode-right-button
*
98 '((:top-left present-clfswm-terminal
)
99 (:top-right ask-close
/kill-current-window
)
100 (:bottom-right expose-all-windows-mode
)
102 'Corner
"Actions on corners in the main mode with the right mouse button")
104 (defconfig *corner-second-mode-left-button
*
107 (:bottom-right expose-windows-mode
)
109 'Corner
"Actions on corners in the second mode with the left mouse button")
111 (defconfig *corner-second-mode-middle-button
*
112 '((:top-left help-on-clfswm
)
116 'Corner
"Actions on corners in the second mode with the middle mouse button")
118 (defconfig *corner-second-mode-right-button
*
121 (:bottom-right expose-all-windows-mode
)
123 'Corner
"Actions on corners in the second mode with the right mouse button")
126 (defconfig *virtual-keyboard-cmd
* "xvkbd"
127 'Corner
"The command to display the virtual keybaord
128 Here is an ~/.Xresources example for xvkbd:
129 xvkbd.windowGeometry: 300x100-0-0
131 xvkbd.modalKeytop: true
132 xvkbd.customization: -french
134 And make it always on top")
136 (defconfig *clfswm-terminal-name
* "clfswm-terminal"
137 'Corner
"The clfswm terminal name")
138 ;;(defparameter *clfswm-terminal-cmd* (format nil "xterm -T ~A -e /bin/bash --noprofile --norc" *clfswm-terminal-name*)
139 ;;(defparameter *clfswm-terminal-cmd* (format nil "urxvt -name ~A" *clfswm-terminal-name*)
140 (defconfig *clfswm-terminal-cmd
* (format nil
"xterm -T ~A" *clfswm-terminal-name
*)
141 'Corner
"The clfswm terminal command.
142 This command must set the window title to *clfswm-terminal-name*")
149 ;;; A hook is a function, a symbol or a list of functions with a rest
152 ;;; This hooks are set in clfswm.lisp, you can overwrite them or extend
153 ;;; them with a hook list.
155 ;;; See clfswm.lisp for hooks examples.
157 (defconfig *init-hook
* '(default-init-hook display-hello-window
)
158 'Hook
"Init hook. This hook is run just after the first root frame is created")
160 (defconfig *close-hook
* '(close-notify-window close-clfswm-terminal close-virtual-keyboard
)
161 'Hook
"Close hook. This hook is run just before closing the display")
163 (defconfig *default-nw-hook
* 'default-frame-nw-hook
164 'Hook
"Default action to do on newly created windows")
170 (defconfig *create-frame-on-root
* nil
171 nil
"Create frame on root.
172 Set this variable to true if you want to allow to create a new frame
173 on the root window in the main mode with the mouse")
176 ;;; CONFIG: Main mode colors
177 (defconfig *color-selected
* "Red"
178 'Main-mode
"Color of selected window")
179 (defconfig *color-unselected
* "Blue"
180 'Main-mode
"Color of unselected color")
181 (defconfig *color-maybe-selected
* "Yellow"
182 'Main-mode
"Color of maybe selected windows")
185 ;;; CONFIG: Frame colors
186 (defconfig *frame-background
* "Black"
187 'Frame-colors
"Frame background")
188 (defconfig *frame-foreground
* "Green"
189 'Frame-colors
"Frame foreground")
190 (defconfig *frame-foreground-root
* "Red"
191 'Frame-colors
"Frame foreground when the frame is the root frame")
192 (defconfig *frame-foreground-hidden
* "Darkgreen"
193 'Frame-colors
"Frame foreground for hidden windows")
195 ;;; CONFIG: Default window size
196 (defconfig *default-window-width
* 400
197 nil
"Default window width")
198 (defconfig *default-window-height
* 300
199 nil
"Default window height")
201 ;;; CONFIG: Second mode colors and fonts
202 (defconfig *sm-border-color
* "Green"
203 'Second-mode
"Second mode window border color")
204 (defconfig *sm-background-color
* "Black"
205 'Second-mode
"Second mode window background color")
206 (defconfig *sm-foreground-color
* "Red"
207 'Second-mode
"Second mode window foreground color")
208 (defconfig *sm-font-string
* *default-font-string
*
209 'Second-mode
"Second mode window font string")
210 (defconfig *sm-width
* 300
211 'Second-mode
"Second mode window width")
212 (defconfig *sm-height
* 25
213 'Second-mode
"Second mode window height")
219 ;;; CONFIG - Identify key colors
220 (defconfig *identify-font-string
* *default-font-string
*
221 'Identify-key
"Identify window font string")
222 (defconfig *identify-background
* "black"
223 'Identify-key
"Identify window background color")
224 (defconfig *identify-foreground
* "green"
225 'Identify-key
"Identify window foreground color")
226 (defconfig *identify-border
* "red"
227 'Identify-key
"Identify window border color")
229 ;;; CONFIG - Query string colors
230 (defconfig *query-font-string
* *default-font-string
*
231 'Query-string
"Query string window font string")
232 (defconfig *query-background
* "black"
233 'Query-string
"Query string window background color")
234 (defconfig *query-message-color
* "yellow"
235 'Query-string
"Query string window message color")
236 (defconfig *query-foreground
* "green"
237 'Query-string
"Query string window foreground color")
238 (defconfig *query-cursor-color
* "white"
239 'Query-string
"Query string window foreground cursor color")
240 (defconfig *query-parent-color
* "blue"
241 'Query-string
"Query string window parenthesis color")
242 (defconfig *query-parent-error-color
* "red"
243 'Query-string
"Query string window parenthesis color when no match")
244 (defconfig *query-border
* "red"
245 'Query-string
"Query string window border color")
248 ;;; CONFIG - Info mode
249 (defconfig *info-background
* "black"
250 'Info-mode
"Info window background color")
251 (defconfig *info-foreground
* "green"
252 'Info-mode
"Info window foreground color")
253 (defconfig *info-border
* "red"
254 'Info-mode
"Info window border color")
255 (defconfig *info-line-cursor
* "white"
256 'Info-mode
"Info window line cursor color color")
257 (defconfig *info-selected-background
* "blue"
258 'Info-mode
"Info selected item background color")
259 (defconfig *info-font-string
* *default-font-string
*
260 'Info-mode
"Info window font string")
262 (defconfig *info-click-to-select
* t
263 'Info-mode
"If true, click on info window select item. Otherwise, click to drag the menu")
265 ;;; CONFIG - Circulate string colors
266 (defconfig *circulate-font-string
* *default-font-string
*
267 'Circulate-mode
"Circulate string window font string")
268 (defconfig *circulate-background
* "black"
269 'Circulate-mode
"Circulate string window background color")
270 (defconfig *circulate-foreground
* "green"
271 'Circulate-mode
"Circulate string window foreground color")
272 (defconfig *circulate-border
* "red"
273 'Circulate-mode
"Circulate string window border color")
274 (defconfig *circulate-width
* 400
275 'Circulate-mode
"Circulate mode window width")
276 (defconfig *circulate-height
* 15
277 'Circulate-mode
"Circulate mode window height")
280 (defconfig *circulate-text-limite
* 30
281 'Circulate-mode
"Maximum text limite in the circulate window")
284 ;;; CONFIG - Expose string colors
285 (defconfig *expose-font-string
* *default-font-string
*
286 'Expose-mode
"Expose string window font string")
287 (defconfig *expose-background
* "black"
288 'Expose-mode
"Expose string window background color")
289 (defconfig *expose-foreground
* "green"
290 'Expose-mode
"Expose string window foreground color")
291 (defconfig *expose-border
* "red"
292 'Expose-mode
"Expose string window border color")
293 (defconfig *expose-valid-on-key
* t
294 'Expose-mode
"Valid expose mode when an accel key is pressed")
295 (defconfig *expose-show-window-title
* t
296 'Expose-mode
"Show the window title on accel window")
300 ;;; CONFIG - Show key binding colors
301 (defconfig *info-color-title
* "Magenta"
302 'Info-mode
"Colored info title color")
303 (defconfig *info-color-underline
* "Yellow"
304 'Info-mode
"Colored info underline color")
305 (defconfig *info-color-first
* "Cyan"
306 'Info-mode
"Colored info first color")
307 (defconfig *info-color-second
* "lightblue"
308 'Info-mode
"Colored info second color")
311 ;;; CONFIG - Menu colors
312 ;;; Set *info-foreground* to change the default menu foreground
313 (defconfig *menu-color-submenu
* "Cyan"
314 'Menu
"Submenu color in menu")
315 (defconfig *menu-color-comment
* "Yellow"
316 'Menu
"Comment color in menu")
317 (defconfig *menu-color-key
* "Magenta"
318 'Menu
"Key color in menu")
319 (defconfig *menu-color-menu-key
* (->color
#xFF9AFF
)
320 'Menu
"Menu key color in menu")
323 ;;; CONFIG - Notify window string colors
324 (defconfig *notify-window-font-string
* *default-font-string
*
325 'Notify-Window
"Notify window font string")
326 (defconfig *notify-window-background
* "black"
327 'Notify-Window
"Notify Window background color")
328 (defconfig *notify-window-foreground
* "green"
329 'Notify-Window
"Notify Window foreground color")
330 (defconfig *notify-window-border
* "red"
331 'Notify-Window
"Notify Window border color")
332 (defconfig *notify-window-delay
* 10
333 'Notify-Window
"Notify Window display delay")