(in-package :stumpwm) (setq *startup-message* nil) (setq *startup-mode-line* t) (set-module-dir "~/stumpwm/contrib") ;; Modeline Battery (load-module "battery-portable") (load-module "cpu") (load-module "mem") (setf *mode-line-pad-x* 8 *mode-line-pad-y* 1 *mode-line-timeout* 1 *window-border-style* :thin *frame-number-map* "1234567890" *mode-line-position* :top *window-format* "%m%n%s%c" *cpu-modeline-fmt* "%C" *window-name-source* :class *delim* " ^2::^7 " *screen-mode-line-format* (list ;; Windows ;;"[^B%n^b]" "^7%W ^>^7" ;; CPU "%C" *delim* ;; RAM "%M" *delim* ;; Battery "%B" *delim* ;; Date "%d" )) ;; launch Web browser (defcommand next () () "Start Icecat or switch to it, if it is already running." (run-or-raise "next" '(:class "Next"))) (define-key *root-map* (kbd "B") "next") ;; launch terminal (defcommand urxvt () () "Start Urxvt or switch to it, if it is already running." (run-or-raise "urxvt" '(:class "Urxvt"))) (define-key *root-map* (kbd "c") "urxvt") ;; Change xterm to urxvt (define-key *root-map* (kbd "C") "exec urxvt") ;; Change emacs to emacsclient (defcommand emacsclient () () "Start Urxvt or switch to it, if it is already running." (run-or-raise "emacsclient -c -a emaces" '(:class "Emacs"))) (define-key *root-map* (kbd "e") "emacsclient -c -a emaces") ;; Volume Management (progn (define-key *top-map* (kbd "XF86AudioLowerVolume") "exec amixer -q sset Master 3%-") (define-key *top-map* (kbd "XF86AudioRaiseVolume") "exec amixer -q sset Master 3%+") (define-key *top-map* (kbd "XF86AudioMute") "amixer -q sset Master toggle")) ;; Mode-line (progn (enable-mode-line (current-screen) (current-head) t))