From: Jay Belanger Date: Wed, 5 Nov 2008 22:12:21 +0000 (+0000) Subject: (calc-quit): Use `window-full-width-p' to check window width. X-Git-Tag: emacs-pretest-23.0.90~1954 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=a2baa908022e3459e12eb4c7ce701f8391cf06c2;p=emacs.git (calc-quit): Use `window-full-width-p' to check window width. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 213b7065c19..029d7375580 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-11-05 Jay Belanger + + * calc/calc.el (calc-quit): Use `window-full-width-p' to check + window width. + 2008-11-05 Chong Yidong * server.el (server-process-filter): Only default to emacsclient's diff --git a/lisp/calc/calc.el b/lisp/calc/calc.el index 4c6375b1183..395ac8fe975 100644 --- a/lisp/calc/calc.el +++ b/lisp/calc/calc.el @@ -1424,9 +1424,12 @@ commands given here will actually operate on the *Calculator* stack." (win (get-buffer-window (current-buffer))) (kbuf (get-buffer "*Calc Keypad*"))) (delete-windows-on (calc-trail-buffer)) + ;; The next few lines will set `calc-window-height' so that the + ;; next time Calc is called, the window will be the same size + ;; as the current window. (if (and win (< (window-height win) (1- (frame-height))) - (= (window-width win) (frame-width)) ; avoid calc-keypad + (window-full-width-p win) ; avoid calc-keypad (not (get-buffer-window "*Calc Keypad*"))) (setq calc-window-height (- (window-height win) 2))) (progn