at commit a262df09

1 ;;;; common lisp window manager
2 ;;;;
3 ;;;; forms intended to be executed as wm commands
4
5 (in-package #:clwm-ext)
6
7 ;;; respecting POINTER-KEYBINDS-MIXIN convention
8
9 (defun spawn-command (program &rest args)
10 "Spawns a program.
11 Respects POINTER-KEYBINDS-MIXIN convention."
12 (lambda (wm &rest pointer)
13 (declare (ignore pointer))
14 (apply #'spawn wm program args)))
15
16 (defun close-command (wm client x y)
17 "Close the client under the pointer.
18 Respects POINTER-KEYBINDS-MIXIN convention."
19 (declare (ignore x y))
20 (when client (close-client wm client)))
21
22 (defun hide-command (wm client x y)
23 "Hide the client under the pointer.
24 Respects POINTER-KEYBINDS-MIXIN convention."
25 (declare (ignore x y))
26 (when client (hide-client wm client)))
27
28 (defun raise-command (wm client x y)
29 "Raise the client under the pointer.
30 Respects POINTER-KEYBINDS-MIXIN convention."
31 (declare (ignore x y))
32 (when client (configure-client wm client :stack-mode :above)))
33
34 (defun lower-command (wm client x y)
35 "Lower the client under the pointer.
36 Respects POINTER-KEYBINDS-MIXIN convention."
37 (declare (ignore x y))
38 (when client (configure-client wm client :stack-mode :below)))