Can use default-frame-alist and initial-frame-alist

This commit is contained in:
Tom Willemsen 2011-08-12 15:09:05 +02:00
parent b5a44717db
commit cd6ac84014
2 changed files with 3 additions and 15 deletions

View file

@ -88,13 +88,6 @@ Currently adds | & ! . + = - / % * , < > ? : ->"
"Find out which major-mode is currently used" "Find out which major-mode is currently used"
(with-current-buffer buffer-or-string major-mode)) (with-current-buffer buffer-or-string major-mode))
(defun setup-system-frame-colours (&rest frame)
(let ((f (if (car frame)
(car frame)
(selected-frame))))
(progn
(set-frame-font "-*-tamsyn-medium-*-*-*-15-*-*-*-*-80-*-*"))))
(defun show-init-sections () (defun show-init-sections ()
(interactive) (interactive)
(occur ";;\s +.*\s +;;") (occur ";;\s +.*\s +;;")

View file

@ -152,12 +152,6 @@
(defvar font-lock-operator-face 'font-lock-operator-face) (defvar font-lock-operator-face 'font-lock-operator-face)
(defvar font-lock-end-statement 'font-lock-end-statement) (defvar font-lock-end-statement 'font-lock-end-statement)
(defadvice server-create-window-system-frame
(after set-system-frame-colours ())
"Set custom frame colours when creating the first frame on a display"
(message "Running after frame-initialize")
(setup-system-frame-colours))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; SETTINGS ;; ;; SETTINGS ;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@ -190,7 +184,9 @@
`((".*" ,temporary-file-directory t))) `((".*" ,temporary-file-directory t)))
(setq default-frame-alist ; default frame settings (setq default-frame-alist ; default frame settings
(append '((font . "DejaVu Sans Mono-10:antialias=true")))) (append '((font . "DejaVu Sans Mono-10:antialias=true"))))
(setq initial-frame-alist ; initial frame settings
(append '((font . "DejaVu Sans Mono-10:antialias=true"))))
(if window-system (if window-system
(x-init) (x-init)
@ -345,7 +341,6 @@
"?>\n" "?>\n"
'(indent-region (point-min) (point-max))) '(indent-region (point-min) (point-max)))
(ad-activate 'server-create-window-system-frame)
(add-html-keywords) (add-html-keywords)
(make-face 'font-lock-operator-face) (make-face 'font-lock-operator-face)
(make-face 'font-lock-end-statement) (make-face 'font-lock-end-statement)