The function `display-buffer' sometimes splits a window with a call to `split-window'. This split is always done vertically, i.e. the two windows are above/below each other. I find it un-emacs like for this behaviour to be hard coded and it doesn't suite everybody.
I propose to introduce the variable `prefer-window-split-horizontally' that can be set to `t' to have `display-buffer' call `split-window' with it's `horflag' parameter set to `t' instead of `nil'. The new variable can also be set to an integer value that means that windows should be split horizontally but only if the resulting windows are at least as wide as that value. I my self set the value to 80 so that whenever the frame is wide enough to have two 80-column windows side-by-side, display-buffer splits horizontally. The attached patch defines the variable and modifies `display-buffer' in src/window.c. It also adds the variable to lisp/cus-start.el. I am new to posting patches and am happy for all kinds of feedback. /Fredrik Axelsson
prefer-window-split-horizontally.patch
Description: Binary data
_______________________________________________ emacs-pretest-bug mailing list [email protected] http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug
