diff options
author | Yuuki Harano <masm+github@masm11.me> | 2021-11-11 00:39:53 +0900 |
---|---|---|
committer | Yuuki Harano <masm+github@masm11.me> | 2021-11-11 00:39:53 +0900 |
commit | 4dd1f56f29fc598a8339a345c2f8945250600602 (patch) | |
tree | af341efedffe027e533b1bcc0dbf270532e48285 /lisp/startup.el | |
parent | 4c49ec7f865bdad1629d2f125f71f4e506b258f2 (diff) | |
parent | 810fa21d26453f898de9747ece7205dfe6de9d08 (diff) | |
download | emacs-4dd1f56f29fc598a8339a345c2f8945250600602.tar.gz emacs-4dd1f56f29fc598a8339a345c2f8945250600602.tar.bz2 emacs-4dd1f56f29fc598a8339a345c2f8945250600602.zip |
Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs into feature/pgtk
Diffstat (limited to 'lisp/startup.el')
-rw-r--r-- | lisp/startup.el | 22 |
1 files changed, 18 insertions, 4 deletions
diff --git a/lisp/startup.el b/lisp/startup.el index c13846a05ba..80253211617 100644 --- a/lisp/startup.el +++ b/lisp/startup.el @@ -549,7 +549,11 @@ It is the default value of the variable `top-level'." ;; When $HOME is set to '/nonexistent' means we are running the ;; testsuite, add a temporary folder in front to produce there ;; new compilations. - (when (equal (getenv "HOME") "/nonexistent") + (when (and (equal (getenv "HOME") "/nonexistent") + ;; We may be running in a chroot environment where we + ;; can't write anything. + (file-writable-p (expand-file-name + (or temporary-file-directory "")))) (let ((tmp-dir (make-temp-file "emacs-testsuite-" t))) (add-hook 'kill-emacs-hook (lambda () (delete-directory tmp-dir t))) (push tmp-dir native-comp-eln-load-path)))) @@ -1784,9 +1788,19 @@ a face or button specification." (window-width (window-width))) (when img (when (> window-width image-width) - ;; Center the image in the window. - (insert (propertize " " 'display - `(space :align-to (+ center (-0.5 . ,img))))) + ;; Center the image above text. + ;; NB. The logo used to be centered in the window, which made + ;; it align poorly with the non-centered text on large + ;; displays. Arguably it would be better to center both + ;; text and image, but this will do for now. -- SK + (let ((text-width 80) + ;; The below value chosen to avoid splash screen being + ;; visually unbalanced. This needs to be eye-balled. + (adjust-left 3)) + (insert (propertize " " 'display + `(space :align-to (+ ,(- (/ text-width 2) + adjust-left) + (-0.5 . ,img)))))) ;; Change the color of the XPM version of the splash image ;; so that it is visible with a dark frame background. |