[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Windows splitting: prefer only 2 windows horizontal spliting.
From: |
Perry Smith |
Subject: |
Re: Windows splitting: prefer only 2 windows horizontal spliting. |
Date: |
Sun, 20 Feb 2011 17:07:39 -0600 |
On Feb 20, 2011, at 2:52 PM, Oleksandr Gavenko (aka gavenkoa) wrote:
> How prefer horizontal splitting I know:
>
> (when window-system
> ;; Prefer horizontal windows splitting.
> (setq split-height-threshold 0)
> (setq split-width-threshold nil)
> )
>
> But how stop Emacs from splitting when already 2 windows?
> So reuse existing window.
>
> For example I edit file (1 window) then M-x compile (2 windows)
> then C-x ` (2 windows, *Compilation* and source with error) -
> no other window appear.
>
> Emacs 23.1/22.3/21.4 work in such way on Debian, but new Emacs 23.2.1
> work different.
>
> For example: open file, C-x v l (new window show log),
> d (new window show diff, there are 3 windows now),
> M-x man printf RET (new window show man, there 4 windows now).
>
> So how force Emacs display no more that 2 windows at same time?
This is not exactly what you were asking for. I wanted to get emacs to
do what it was doing before. I followed the instructions but found
that it kept creating smaller and smaller windows. So, now I leave
split-height-threshold alone and do this (this is inside my
.emacs.d/init.el file.
(custom-set-variables
...
'(split-width-threshold 1600)
)
which basically says "don't split windows vertically".
Setting it to nil didn't have the effect I was looking for.
pedz