As screen size automatically not detected, determine dimention from user assigned vars.
authorOleksandr Gavenko <gavenkoa@gmail.com>
Sat, 30 Jan 2010 21:24:29 +0200
changeset 285 9883ac39abc3
parent 284 bf5829d9bbf7
child 286 bdbe49f5dea5
As screen size automatically not detected, determine dimention from user assigned vars.
.emacs-my
.emacs-pre
--- a/.emacs-my	Fri Jan 29 16:13:48 2010 +0200
+++ b/.emacs-my	Sat Jan 30 21:24:29 2010 +0200
@@ -1098,10 +1098,11 @@
 
 ;; Size of emacs area and its position.
 (when window-system
-  ;; This size for 1280x1024 resolusion and 13pt font to occupy almost all screen.
   (run-at-time (format "%d sec" 1) nil '(lambda () (set-frame-position (selected-frame) 1 1)))
-  (run-at-time (format "%d sec" 2) nil '(lambda () (set-frame-width (selected-frame) 150 t)))
-  (run-at-time (format "%d sec" 3) nil '(lambda () (set-frame-height (selected-frame) 60 t)))
+  (when (boundp 'my-frame-width)
+    (run-at-time (format "%d sec" 2) nil '(lambda () (set-frame-width (selected-frame) my-frame-width t))) )
+  (when (boundp 'my-frame-height)
+    (run-at-time (format "%d sec" 3) nil '(lambda () (set-frame-height (selected-frame) my-frame-height t))) )
   )
 
 ;; End loading...
--- a/.emacs-pre	Fri Jan 29 16:13:48 2010 +0200
+++ b/.emacs-pre	Sat Jan 30 21:24:29 2010 +0200
@@ -1,2 +1,6 @@
 ;; -*- lisp -*-
 ;; Firstly .emacs load this file, then .emacs-my.
+
+;; Set frame width and heith. 150x46 for 13pt 1280x800, 150x60 for 13pt 1280x1024.
+;; (setq my-frame-width 150)
+;; (setq my-frame-height 60)