[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Behaviour of `compilation-window-height'

From: Philipp G . Haselwarter
Subject: Behaviour of `compilation-window-height'
Date: Mon, 20 Feb 2017 15:45:30 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux)

I was a bit surprised to see that `compilation-window-height' is only
applied when the compilation window is full-width. I think I'd rather it
be honoured also if that is not the case. Can somebody explain the
rationale here?

For convenience, here's the code I'm referring to from compile.el:1826

(defun compilation-set-window-height (window)
  "Set the height of WINDOW according to `compilation-window-height'."
  (let ((height (buffer-local-value 'compilation-window-height (window-buffer 
    (and height
         (window-full-width-p window)
         ;; If window is alone in its frame, aside from a minibuffer,
         ;; don't change its height.
         (not (eq window (frame-root-window (window-frame window))))
         ;; Stef said that doing the saves in this order is safer:
             (select-window window)
             (enlarge-window (- height (window-height))))))))

With kind regards,
Philipp G. Haselwarter

reply via email to

[Prev in Thread] Current Thread [Next in Thread]