Mercurial > emacs
changeset 99234:770ae8d8f7f4
(Electric-pop-up-window): Don't shrink the window if it's already big
enough.
author | Chong Yidong <cyd@stupidchicken.com> |
---|---|
date | Wed, 29 Oct 2008 21:42:37 +0000 |
parents | 49f2f7ce975f |
children | eccf5258acaf |
files | lisp/electric.el |
diffstat | 1 files changed, 3 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/electric.el Wed Oct 29 21:42:28 2008 +0000 +++ b/lisp/electric.el Wed Oct 29 21:42:37 2008 +0000 @@ -153,8 +153,10 @@ (setq win (selected-window))) (t (switch-to-buffer buf))) - (fit-window-to-buffer win max-height) + ;; Don't shrink the window, but expand it if necessary. (goto-char (point-min)) + (unless (= (point-max) (window-end win)) + (fit-window-to-buffer win max-height)) win))) (provide 'electric)