diff options
author | Glenn Morris <rgm@gnu.org> | 2021-01-14 07:50:28 -0800 |
---|---|---|
committer | Glenn Morris <rgm@gnu.org> | 2021-01-14 07:50:28 -0800 |
commit | c83590b12114a0958c8e26846c87c84f492405bc (patch) | |
tree | 3352fc89c72c6b68501f4d66d2828a8377320d8e | |
parent | 4ad332d844b5b441c05c617304853e80a4714d51 (diff) | |
parent | 488204cdc64b6a130042ecc64d59c4538287b81d (diff) | |
download | emacs-c83590b12114a0958c8e26846c87c84f492405bc.tar.gz |
Merge from origin/emacs-27
488204cdc6 (origin/emacs-27) Remove one of recently added warnings ab...
55bc1560ac Fix assertion failure in window_box_height (Bug#45737)
27743e9e70 Fix cl-concatenate inlining
32a3758c84 Fix infloop in 'pixel-scroll-mode'
74d18957b8 Fix inhibiting the default.el loading in user init file
-rw-r--r-- | lisp/emacs-lisp/seq.el | 3 | ||||
-rw-r--r-- | lisp/isearch.el | 4 | ||||
-rw-r--r-- | lisp/pixel-scroll.el | 12 | ||||
-rw-r--r-- | lisp/startup.el | 9 | ||||
-rw-r--r-- | lisp/window.el | 8 |
5 files changed, 21 insertions, 15 deletions
diff --git a/lisp/emacs-lisp/seq.el b/lisp/emacs-lisp/seq.el index 31c15fea90d..64d7e533751 100644 --- a/lisp/emacs-lisp/seq.el +++ b/lisp/emacs-lisp/seq.el @@ -284,6 +284,9 @@ sorted. FUNCTION must be a function of one argument." (cl-defmethod seq-reverse ((sequence sequence)) (reverse sequence)) +;; We are autoloading seq-concatenate because cl-concatenate needs +;; that when it's inlined, per the cl-proclaim in cl-macs.el. +;;;###autoload (cl-defgeneric seq-concatenate (type &rest sequences) "Concatenate SEQUENCES into a single sequence of type TYPE. TYPE must be one of following symbols: vector, string or list. diff --git a/lisp/isearch.el b/lisp/isearch.el index 602643f8ae9..d8d3a731a4b 100644 --- a/lisp/isearch.el +++ b/lisp/isearch.el @@ -838,10 +838,6 @@ This is like `describe-bindings', but displays only Isearch keys." :image '(isearch-tool-bar-image "left-arrow"))) map)) -;; Note: Before adding more key bindings to this map, please keep in -;; mind that any unbound key exits Isearch and runs the command bound -;; to it in the local or global map. So in effect every key unbound -;; in this map is implicitly bound. (defvar minibuffer-local-isearch-map (let ((map (make-sparse-keymap))) (set-keymap-parent map minibuffer-local-map) diff --git a/lisp/pixel-scroll.el b/lisp/pixel-scroll.el index cc0e159faef..68dc0fb94b3 100644 --- a/lisp/pixel-scroll.el +++ b/lisp/pixel-scroll.el @@ -132,8 +132,10 @@ This is an alternative of `scroll-up'. Scope moves downward." (pixel-line-height)))) (if (pixel-eob-at-top-p) ; when end-of-the-buffer is close (scroll-up 1) ; relay on robust method - (while (pixel-point-at-top-p amt) ; prevent too late (multi tries) - (vertical-motion 1)) ; move point downward + (catch 'no-movement + (while (pixel-point-at-top-p amt) ; prevent too late (multi tries) + (unless (>= (vertical-motion 1) 1) ; move point downward + (throw 'no-movement nil)))) ; exit loop when point did not move (pixel-scroll-pixel-up amt)))))) ; move scope downward (defun pixel-scroll-down (&optional arg) @@ -149,8 +151,10 @@ This is and alternative of `scroll-down'. Scope moves upward." pixel-resolution-fine-flag (frame-char-height)) (pixel-line-height -1)))) - (while (pixel-point-at-bottom-p amt) ; prevent too late (multi tries) - (vertical-motion -1)) ; move point upward + (catch 'no-movement + (while (pixel-point-at-bottom-p amt) ; prevent too late (multi tries) + (unless (<= (vertical-motion -1) -1) ; move point upward + (throw 'no-movement nil)))) ; exit loop when point did not move (if (or (pixel-bob-at-top-p amt) ; when beginning-of-the-buffer is seen (pixel-eob-at-top-p)) ; for file with a long line (scroll-down 1) ; relay on robust method diff --git a/lisp/startup.el b/lisp/startup.el index 57fd87f20f9..cc14fb28140 100644 --- a/lisp/startup.el +++ b/lisp/startup.el @@ -921,7 +921,8 @@ the name of the init-file to load. If this file cannot be loaded, and ALTERNATE-FILENAME-FUNCTION is non-nil, then it is called with no arguments and should return the name of an alternate init-file to load. If LOAD-DEFAULTS is non-nil, then -load default.el after the init-file. +load default.el after the init-file, unless `inhibit-default-init' +is non-nil. This function sets `user-init-file' to the name of the loaded init-file, or to a default value if loading is not possible." @@ -977,8 +978,8 @@ init-file, or to a default value if loading is not possible." (sit-for 1)) (setq user-init-file source)))) - (when load-defaults - + (when (and load-defaults + (not inhibit-default-init)) ;; Prevent default.el from changing the value of ;; `inhibit-startup-screen'. (let ((inhibit-startup-screen nil)) @@ -1374,7 +1375,7 @@ please check its value") (expand-file-name "init.el" startup-init-directory)) - (not inhibit-default-init)) + t) (when (and deactivate-mark transient-mark-mode) (with-current-buffer (window-buffer) diff --git a/lisp/window.el b/lisp/window.el index 5bb7d577aa1..719bafccb4f 100644 --- a/lisp/window.el +++ b/lisp/window.el @@ -1736,9 +1736,11 @@ interpret DELTA as pixels." (setq window (window-normalize-window window)) (cond ((< delta 0) - (max (- (window-min-size window horizontal ignore pixelwise) - (window-size window horizontal pixelwise)) - delta)) + (let ((min-size (window-min-size window horizontal ignore pixelwise)) + (size (window-size window horizontal pixelwise))) + (if (<= size min-size) + 0 + (max (- min-size size) delta)))) ((> delta 0) (if (window-size-fixed-p window horizontal ignore) 0 |