From: martin rudalics <rudalics@gmx.at>
To: Eli Zaretskii <eliz@gnu.org>, Aaron Jensen <aaronjensen@gmail.com>
Cc: 64451@debbugs.gnu.org
Subject: bug#64451: 30.0.50; split-root-window-right ignores side windows
Date: Fri, 7 Jul 2023 15:57:12 +0200 [thread overview]
Message-ID: <48e46afc-ff48-a726-e3e6-7fbea5b2ab77@gmx.at> (raw)
In-Reply-To: <83edlliii5.fsf@gnu.org>
[-- Attachment #1: Type: text/plain, Size: 921 bytes --]
>> (display-buffer "*scratch*" '(display-buffer-in-side-window . ((side . right))))
>> M-x split-root-window-right
>>
>> I would expect the new window to be to the left of the side window (I
>> know this is counter-intuitive to splititng the root window, but it's
>> also intuitive given the nature of side windows...)
>>
>> I don't know if this is intentional. I also don't know if it's a
>> regression as it's not behavior I remember seeing until fairly recently.
>
> Martin, any comments?
There are two bugs. The first one is that splitting a root window with
side windows is always an error unless a new side window on another side
should be made. This should be fixed by the attached patch.
The second bug is that the 'split-root-window-...' functions probably
should split 'window-main-window' on that frame instead. I'd rather
leave the fix for that to the people who wrote those functions.
martin
[-- Attachment #2: split-window.diff --]
[-- Type: text/x-patch, Size: 691 bytes --]
diff --git a/lisp/window.el b/lisp/window.el
index 16f16a75418..0ddd04b0696 100644
--- a/lisp/window.el
+++ b/lisp/window.el
@@ -5434,6 +5434,10 @@ split-window
(setq atom-root (window-atom-root window))
(not (eq atom-root window)))
(throw 'done (split-window atom-root size side pixelwise)))
+ ((and (eq window (frame-root-window frame))
+ (not (eq window-combination-resize 'side))
+ (window-with-parameter 'window-side nil frame))
+ (error "Cannot split root window with side windows"))
;; If WINDOW is a side window or its first or last child is a
;; side window, throw an error unless `window-combination-resize'
;; equals 'side.
next prev parent reply other threads:[~2023-07-07 13:57 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-03 23:38 bug#64451: 30.0.50; split-root-window-right ignores side windows Aaron Jensen
2023-07-06 7:52 ` Eli Zaretskii
2023-07-07 13:57 ` martin rudalics [this message]
2023-07-08 9:09 ` Eli Zaretskii
2023-07-15 7:51 ` Eli Zaretskii
2023-07-16 16:54 ` hugo
2023-08-03 7:40 ` Eli Zaretskii
2023-08-12 6:46 ` Eli Zaretskii
2023-08-19 8:20 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=48e46afc-ff48-a726-e3e6-7fbea5b2ab77@gmx.at \
--to=rudalics@gmx.at \
--cc=64451@debbugs.gnu.org \
--cc=aaronjensen@gmail.com \
--cc=eliz@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
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).