dot/emacs: Propagate initial frame's background colour to other frames.
authorMark Wooding <mdw@distorted.org.uk>
Sun, 24 Apr 2016 11:01:56 +0000 (12:01 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Sun, 24 Apr 2016 11:01:56 +0000 (12:01 +0100)
Now the `.xinitrc' Emacs has all of its frames with black backgrounds
and other ancillary Emacsen have all of their frames with blue
backgrounds.  This seems right and useful.

dot/emacs

index 320e03c..7e66c2a 100644 (file)
--- a/dot/emacs
+++ b/dot/emacs
             (background-color . "black")
             (foreground-color . "white"))
        (nil (menu-bar-lines . 0))))
+(let ((backg (frame-parameter nil 'background-color)))
+  (if (and backg window-system)
+      (push (cons 'background-color backg) default-frame-alist)))
 
 ;; Other frame fiddling.