summaryrefslogtreecommitdiffstats
path: root/.stumpwmrc
diff options
context:
space:
mode:
authorGravatar Tom Willemse2013-05-15 16:04:24 +0200
committerGravatar Tom Willemse2013-05-15 16:04:24 +0200
commit93d996f94c3377bb738b0739c5e8477d5d50e7fb (patch)
tree994159ef102e57a447b7ce1f9126ca87e66845ba /.stumpwmrc
parent08e5782f64bdc204166b035a44ae69b1f468e952 (diff)
downloaddotfiles-93d996f94c3377bb738b0739c5e8477d5d50e7fb.tar.gz
dotfiles-93d996f94c3377bb738b0739c5e8477d5d50e7fb.zip
Various updates
The colours patch has not been applied yet to the current version of stumpwm, but it should be so keep the code around. Show a menu with some frequently used programs. Include seen, but unread emails in `get-mail-count'. Again put firefox and conkeror in the right-most frame. Apparently the current version of stumpwm can't find swank, so temporarily remove it. Load a 3-frame desktop setup from a file.
Diffstat (limited to '.stumpwmrc')
-rw-r--r--.stumpwmrc94
1 files changed, 55 insertions, 39 deletions
diff --git a/.stumpwmrc b/.stumpwmrc
index 3b1fb26..3814087 100644
--- a/.stumpwmrc
+++ b/.stumpwmrc
@@ -1,9 +1,9 @@
;; -*- mode: lisp; -*-
-(require 'swank)
+; (require 'swank)
+(require 'cl-ppcre)
(in-package :stumpwm)
-
-(require 'cl-ppcre)
+(load "/usr/share/stumpwm/contrib/app-menu.lisp")
(defmacro elisp (&body body)
"Run BODY through emacsclient."
@@ -13,21 +13,26 @@
:wait nil))
;; Naquadah
-(defun colour (key)
- (let ((colours (list :lblack #xeeeeec :dblack #x111113
- :lwhite #xa5a5a4 :dwhite #x222224
- :lred #xbf6d6d :dred #x744a4a
- :lorange #xbfa47d :dorange #x73634a
- :lyellow #xb2bf6d :dyellow #x6b734a
- :lgreen #x8abf6d :dgreen #x52734a
- :lturquoise #x7dbf97 :dturquoise #x4a735b
- :lcyan #x7dbfbf :dcyan #x4a7373
- :lblue #x6d97bf :dblue #x4a5b73
- :lpurple #x8a7dbf :dpurple #x524a73
- :lmagenta #xb27dbf :dmagenta #x6b4a73
- :lpink #xbf6da4 :dpink #x734a63)))
- (getf colours key)))
-
+ ;; (defun colour (key)
+ ;; (let ((colours (list :lblack #xeeeeec :dblack #x111113
+ ;; :lwhite #xa5a5a4 :dwhite #x222224
+ ;; :lred #xbf6d6d :dred #x744a4a
+ ;; :lorange #xbfa47d :dorange #x73634a
+ ;; :lyellow #xb2bf6d :dyellow #x6b734a
+ ;; :lgreen #x8abf6d :dgreen #x52734a
+ ;; :lturquoise #x7dbf97 :dturquoise #x4a735b
+ ;; :lcyan #x7dbfbf :dcyan #x4a7373
+ ;; :lblue #x6d97bf :dblue #x4a5b73
+ ;; :lpurple #x8a7dbf :dpurple #x524a73
+ ;; :lmagenta #xb27dbf :dmagenta #x6b4a73
+ ;; :lpink #xbf6da4 :dpink #x734a63)))
+ ;; (getf colours key)))
+
+(setf *app-menu* '(("Editor" . "emacs")
+ ("Browser" . "conkeror")
+ ("Terminal" . "urxvt")
+ ("Office" . "libreoffice")
+ ("Gimp" . "gimp")))
(defvar *conkeror-program* "conkeror"
"The executable to run to start Conkeror.")
(defvar *emacs-program* "emacsclient -c -a emacs"
@@ -48,9 +53,16 @@
(defun get-mail-count (mailbox &optional (inbox "inbox"))
"Check how many new messages there are in MAILBOX."
(length
- (directory
- (format nil "/home/slash/documents/mail/~A/~A/new/*.*"
- mailbox inbox))))
+ (append
+ (directory
+ (format nil "/home/slash/documents/mail/~A/~A/new/*.*"
+ mailbox inbox))
+ (remove-if (lambda (d)
+ (let ((dir (namestring d)))
+ (string= dir "S" :start1 (1- (length dir)))))
+ (directory
+ (format nil "/home/slash/documents/mail/~A/~A/cur/*.*"
+ mailbox inbox))))))
(defun mpd-playing-p ()
"Check if MPD is currently in the playing state."
@@ -129,23 +141,23 @@ it and run *screen-unlocked-hook* after it has been unlocked."
"/usr/bin/i3lock" '("-n" "-c" "000000") :wait nil
:status-hook #'run-stumpwm-hook-on-exit))
-(set-bg-color (colour :dwhite))
-(set-border-color (colour :lwhite))
-(set-fg-color (colour :lblack))
-(set-float-focus-color (colour :lblue))
-(set-float-unfocus-color (colour :dwhite))
-(set-focus-color (colour :lblue))
-(set-font "-*-tamsyn-medium-r-normal-*-17-*-*-*-*-0-iso8859-1")
-(set-unfocus-color (colour :dwhite))
-(set-win-bg-color (colour :dblack))
-
-(setf *colors* (mapcar #'colour '(:lwhite :lred :lgreen :lyellow :lblue
- :lmagenta :lcyan :lblack)))
+;; (set-bg-color (colour :dwhite))
+;; (set-border-color (colour :lwhite))
+;; (set-fg-color (colour :lblack))
+;; (set-float-focus-color (colour :lblue))
+;; (set-float-unfocus-color (colour :dwhite))
+;; (set-focus-color (colour :lblue))
+;; (set-font "-*-tamsyn-medium-r-normal-*-17-*-*-*-*-0-iso8859-1")
+;; (set-unfocus-color (colour :dwhite))
+;; (set-win-bg-color (colour :dblack))
+
+;; (setf *colors* (mapcar #'colour '(:lwhite :lred :lgreen :lyellow :lblue
+;; :lmagenta :lcyan :lblack)))
(setf *input-window-gravity* :bottom-left)
(setf *message-window-gravity* :top-right)
-(setf *mode-line-background-color* (colour :dwhite))
-(setf *mode-line-border-color* (colour :dwhite))
-(setf *mode-line-foreground-color* (colour :lblack))
+;; (setf *mode-line-background-color* (colour :dwhite))
+;; (setf *mode-line-border-color* (colour :dwhite))
+;; (setf *mode-line-foreground-color* (colour :lblack))
(setf *shell-program* (getenv "SHELL"))
(setf *transient-border-width* 1)
(setf *window-border-style* :thin)
@@ -191,11 +203,15 @@ it and run *screen-unlocked-hook* after it has been unlocked."
(define-frame-preference "Default"
(0 t nil :class "Emacs")
- (1 t nil :class "Firefox")
+ (2 t nil :class "Firefox")
(1 t nil :class "URxvt")
- (1 t nil :class "Conkeror"))
+ (2 t nil :class "Conkeror"))
(if (not (head-mode-line (current-head)))
(toggle-mode-line (current-screen) (current-head)))
-(swank:create-server)
+(restore-from-file
+ (concatenate 'string (sb-ext:posix-getenv "HOME")
+ "/.stumpwm.d/desktop.lisp"))
+
+; (swank:create-server)