Subject: Re: bug#56767: New commands to split frame

From: Lars Ingebrigtsen <[email-masked]>
Date: Tue, 26 Jul 2022 14:41:48 +0200

Juri Linkov <[email-masked]> writes:

> Since we already have the commands to split the current window,
> shouldn't we also have the commands to split the current frame:
>
> ```
> diff --git a/lisp/window.el b/lisp/window.el
> index 4d88ffa903..86dec25cdf 100644
> --- a/lisp/window.el
> +++ b/lisp/window.el
> @@ -5754,6 +5754,17 @@ split-window-right
>      new-window))
>
>  (defalias 'split-window-horizontally 'split-window-right)
> +
> +(defun split-frame-vertically (&optional size)
> +  "Like `split-window-vertically' but splits frame instead of window."
> +  (interactive "P")
> +  (split-window (frame-root-window) size))
> +
> +(defun split-frame-horizontally (&optional size)
> +  "Like `split-window-horizontally' but splits frame instead of window."
> +  (interactive "P")
> +  (split-window (frame-root-window) size t))

I don't think I understand what this is supposed to do.  When testing
it, it just splits the topmost window (no matter what window is
selected), and I don't undertand why anybody would want that in
particular.