]> code.delx.au - gnu-emacs/commitdiff
Fix splash screen display at startup
authorEli Zaretskii <eliz@gnu.org>
Fri, 25 Mar 2016 07:45:39 +0000 (10:45 +0300)
committerEli Zaretskii <eliz@gnu.org>
Fri, 25 Mar 2016 07:45:39 +0000 (10:45 +0300)
* src/frame.c (DEFAULT_ROWS): Enlarge to 36, so that the initial
window displayed by "emacs -q" has enough space to show the whole
text even if it includes 2 lines talking about recovering crashes
sessions.  (Bug#23074)

* lisp/startup.el (use-fancy-splash-screens-p): Fix off-by-one
error when computing the window-height from frame-height.

* etc/NEWS: Mention the change.

etc/NEWS
lisp/startup.el
src/frame.c

index 3defc1914ed7090a41d8dbc40220fb1f431c6de0..35f93410e8fe79c7c6325dec3519f30baaa62485 100644 (file)
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -123,6 +123,12 @@ command line when 'initial-buffer-choice' is non-nil.
 ** The value of 'initial-scratch-message' is now treated as a doc string
 and can contain escape sequences for command keys, quotes, and the like.
 
+---
+** The default height of GUI frames was enlarged.
+This is so there's enough space in the initial window to display the
+optional text about recovering crashes sessions, without losing the
+splash image display.
+
 \f
 * Changes in Emacs 25.1
 
index 15a79f6f5bf1a40ff000ce305971fea9dbb2052b..536289c389144ed647ad601e0065f5e2b8a0496e 100644 (file)
@@ -1890,10 +1890,12 @@ we put it on this frame."
       (when frame
        (let* ((img (create-image (fancy-splash-image-file)))
               (image-height (and img (cdr (image-size img nil frame))))
-              ;; We test frame-height so that, if the frame is split
-              ;; by displaying a warning, that doesn't cause the normal
-              ;; splash screen to be used.
-              (frame-height (1- (frame-height frame))))
+              ;; We test frame-height and not window-height so that,
+              ;; if the frame is split by displaying a warning, that
+              ;; doesn't cause the normal splash screen to be used.
+              ;; We subtract 2 from frame-height to account for the
+              ;; echo area and the mode line.
+              (frame-height (- (frame-height frame) 2)))
          (> frame-height (+ image-height 19)))))))
 
 
index 7511d5323cac96507686375f5d7fd2aa16230475..53ff05965c154c590fd26af34740b351e31f6615 100644 (file)
@@ -4565,7 +4565,7 @@ On Nextstep, this just calls `ns-parse-geometry'.  */)
 
    This function does not make the coordinates positive.  */
 
-#define DEFAULT_ROWS 35
+#define DEFAULT_ROWS 36
 #define DEFAULT_COLS 80
 
 long