]> code.delx.au - gnu-emacs-elpa/commitdiff
Make *LV* window fixed size
authorOleh Krehel <ohwoeowho@gmail.com>
Thu, 30 Apr 2015 07:44:12 +0000 (09:44 +0200)
committerOleh Krehel <ohwoeowho@gmail.com>
Thu, 30 Apr 2015 07:44:12 +0000 (09:44 +0200)
* lv.el (lv-window): Prevent `balance-windows' and the like from messing
  things up.
(lv-message): Bind `window-size-fixed' to nil for
`fit-window-to-buffer'.

Fixes #64

lv.el

diff --git a/lv.el b/lv.el
index f03e73bec3380694d12277bc42cd7cbbd364dca3..463475784881e7a39561d62e6e3218dc925999f6 100644 (file)
--- a/lv.el
+++ b/lv.el
@@ -68,6 +68,7 @@ Only the background color is significant."
             (switch-to-buffer buf)
           (switch-to-buffer "*LV*")
           (set-window-hscroll lv-wnd 0)
+          (setq window-size-fixed t)
           (setq mode-line-format nil)
           (setq cursor-type nil)
           (set-window-dedicated-p lv-wnd t)
@@ -96,7 +97,8 @@ Only the background color is significant."
            (propertize "\n" 'face 'lv-separator 'line-height t)))
         (setq-local window-min-height n-lines)
         (setq truncate-lines (> n-lines 1))
-        (let ((window-resize-pixelwise t))
+        (let ((window-resize-pixelwise t)
+              (window-size-fixed nil))
           (fit-window-to-buffer nil nil 1)))
       (goto-char (point-min)))))