[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: opening two documents side-by-side
From: |
Giorgos Keramidas |
Subject: |
Re: opening two documents side-by-side |
Date: |
Sun, 17 Aug 2008 04:26:05 +0300 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) |
On Sat, 16 Aug 2008 12:51:03 -0700, "Rich E" <reakinator@gmail.com> wrote:
> Hi,
> When I open documents with, for example:
>
> emacs doc1.txt doc2.txt
>
> they will open one above the other. Is there any way two tell emacs
> to open them side by side instead?
Yes, there are a few ways:
* Use an Emacs window that is ``wide enough''. GNU Emacs 23.X decides
if a frame should be split vertically by comparing the current frame
width with `split-width-threshold'. When the current frame width
exceeds `split-width-threshold' Emacs splits the frame in two
vertical windows.
You can try this, for example, by running Emacs (in a terminal that
is at least 40 columns wide) like this:
% emacs --eval '(setq-default split-width-threshold 40)' \
doc1.txt doc2.txt
If your terminal is at least 40 columns wide, Emacs should split the
initial frame in two vertical windows.
* Customize `split-width-threshold' by typing `M-x customize-variable
RET split-width-threshold RET', set its value to a smaller width
than the default (set to 160 columns here), save the customization
for future sessions and you are done. Now Emacs should split the
frame vertically without the --eval trick shown above.
* Fire up Emacs, set up the windows yourself, and *then* visit the two
files in the windows you have pre-configured.