* I prefer horizontal split of windows
@ 2005-11-25 13:21 Joakim Hove
2005-11-25 15:16 ` Johan Bockgård
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Joakim Hove @ 2005-11-25 13:21 UTC (permalink / raw)
Hello,
when emacs displays 'extra' information, i.e. the results from M-x
apropos it splits the frame in two windows vertically. Now, I
generally prefer vertical splits, and would like this to be the
default. My plan for how to achieve this was by splitting the frame in
two windows horizontally *prior* to the (internal) split window call
in the relevant emacs functions. To achieve this I would like to
advice the relevant function, but I don't know which function this is.
So if you have followed this far: which function should I advice? And,
how could I find out this myself (with a trace/debugger??)?
Best Regards
Joakim Hove
--
Joakim Hove
hove AT ntnu.no /
Tlf: +47 (55 5)8 27 13 / Stabburveien 18
Fax: +47 (55 5)8 94 40 / N-5231 Paradis
http://www.ift.uib.no/~hove/ / 55 91 28 18 / 92 68 57 04
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: I prefer horizontal split of windows
2005-11-25 13:21 I prefer horizontal split of windows Joakim Hove
@ 2005-11-25 15:16 ` Johan Bockgård
2005-11-25 17:45 ` rgb
2005-11-26 2:12 ` rgb
2 siblings, 0 replies; 5+ messages in thread
From: Johan Bockgård @ 2005-11-25 15:16 UTC (permalink / raw)
Joakim Hove <hove@ntnu.no> writes:
> when emacs displays 'extra' information, i.e. the results from M-x
> apropos it splits the frame in two windows vertically. Now, I
> generally prefer vertical splits, and would like this to be the
> default.
Investigate "special display" (or `display-buffer-function' etc). See
(info "(elisp)Choosing Window").
--
Johan Bockgård
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: I prefer horizontal split of windows
2005-11-25 13:21 I prefer horizontal split of windows Joakim Hove
2005-11-25 15:16 ` Johan Bockgård
@ 2005-11-25 17:45 ` rgb
2005-11-26 2:12 ` rgb
2 siblings, 0 replies; 5+ messages in thread
From: rgb @ 2005-11-25 17:45 UTC (permalink / raw)
> when emacs displays 'extra' information, i.e. the results from M-x
> apropos it splits the frame in two windows vertically. Now, I
> generally prefer vertical splits
switch-to-buffer-other-window looks to me to be the most promising
place
for advise. But a bug report might be a good path too.
switch-to-buffer-other-window calls pop-to-buffer which hard codes nil
as
the direction to split.
Fdisplay_buffer (buf, other_window, Qnil)
That hard coding could easily reference a variable whose default value
was nil, thus no impact to current users but it would allow anyone to
simply customize it to their liking. I've got a cinematic monitor and
would prefer splits go the other way too.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: I prefer horizontal split of windows
2005-11-25 13:21 I prefer horizontal split of windows Joakim Hove
2005-11-25 15:16 ` Johan Bockgård
2005-11-25 17:45 ` rgb
@ 2005-11-26 2:12 ` rgb
2005-11-28 9:06 ` Joakim Hove
2 siblings, 1 reply; 5+ messages in thread
From: rgb @ 2005-11-26 2:12 UTC (permalink / raw)
> when emacs displays 'extra' information, i.e. the results from M-x
> apropos it splits the frame in two windows vertically. Now, I
> generally prefer vertical splits, and would like this to be the
> default.
I'd say switch-to-buffer-other-window is a likely spot for advise.
But a bug report might do better in the long run.
That calls pop-to-buffer which hard codes nil in it's call to
display-buffer.
Fdisplay_buffer (buf, other_window, Qnil)
This could easily pass a customizable boolean variable.
Since I have several cinema style monitors I would definitely
be flipping that toggle were it available.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: I prefer horizontal split of windows
2005-11-26 2:12 ` rgb
@ 2005-11-28 9:06 ` Joakim Hove
0 siblings, 0 replies; 5+ messages in thread
From: Joakim Hove @ 2005-11-28 9:06 UTC (permalink / raw)
Hello,
thank you both 'rgb' and Johan for answering.
> I'd say switch-to-buffer-other-window is a likely spot for advise.
I have tried advising both switch-to-buffer-other-window, and
diplay-buffer. That works for e.g. M-x manual-entry, i.e. the man page
is displayed in a vertical window, but unfortunately *not* for
e.g. C-h x or tab completion.
> But a bug report might do better in the long run.
> That calls pop-to-buffer which hard codes nil in it's call to
> display-buffer.
>
> Fdisplay_buffer (buf, other_window, Qnil)
Yes, it seems like the call to Fsplit_window() in Fdisplay_buffer()
has a hard-coded nil value, and I certainly agree that there should
be room for user-customization there. However, the fact that advising
(display-buffer) does not do the trick, seems to indicate that other
functions are involved for some of these cases, e.g. for the C-h
family of functions.
Anyway, I have a partial solution.
Joakim
--
Joakim Hove
hove AT ntnu.no /
Tlf: +47 (55 5)8 27 13 / Stabburveien 18
Fax: +47 (55 5)8 94 40 / N-5231 Paradis
http://www.ift.uib.no/~hove/ / 55 91 28 18 / 92 68 57 04
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2005-11-28 9:06 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-11-25 13:21 I prefer horizontal split of windows Joakim Hove
2005-11-25 15:16 ` Johan Bockgård
2005-11-25 17:45 ` rgb
2005-11-26 2:12 ` rgb
2005-11-28 9:06 ` Joakim Hove
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).