[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: switch-to-buffer-other-window to split vertically by default ?
From: |
Romain Francoise |
Subject: |
Re: switch-to-buffer-other-window to split vertically by default ? |
Date: |
Fri, 09 Jun 2006 11:15:34 +0200 |
Bastien <bzgNOSPAM@altern.org> writes:
> everything is in the subject line: i would like
> `switch-to-buffer-other-window' to split the window *vertically* when
> no other window is open.
It's not possible at the moment with a vanilla Emacs, the function that
splits the window (`display-buffer') is in the C code and isn't easily
customizable. This will change after the 22.1 release.
However, if you use Debian's emacs-snapshot version, the following will
do the trick:
(defadvice switch-to-buffer-other-window (around change-split activate)
(let ((display-buffer-prefer-horizontal-split t))
ad-do-it))
--
Romain Francoise <romain@orebokech.com> | The sea! the sea! the open
it's a miracle -- http://orebokech.com/ | sea! The blue, the fresh, the
| ever free! --Bryan W. Procter