mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 10:30:25 -08:00
(shrink-window-if-larger-than-buffer): Don't shrink if the window that would
expand is the minibuffer.
This commit is contained in:
parent
b5b4d63605
commit
5e2ec73efb
1 changed files with 9 additions and 2 deletions
|
|
@ -156,9 +156,16 @@ or if the window is the only window of its frame."
|
|||
(window-min-height 0)
|
||||
(buffer-read-only nil)
|
||||
(modified (buffer-modified-p))
|
||||
(buffer (current-buffer)))
|
||||
(buffer (current-buffer))
|
||||
(mini (cdr (assq 'minibuffer (frame-parameters))))
|
||||
(edges (window-edges (selected-window))))
|
||||
(if (and (< 1 (count-windows))
|
||||
(pos-visible-in-window-p (point-min) window))
|
||||
(pos-visible-in-window-p (point-min) window)
|
||||
(or (not mini)
|
||||
(< (nth 3 edges)
|
||||
(nth 1 (window-edges mini)))
|
||||
(> (nth 1 edges)
|
||||
(cdr (assq 'menu-bar-lines (frame-parameters))))))
|
||||
(unwind-protect
|
||||
(progn
|
||||
(select-window (or window w))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue