1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-23 07:19:15 +00:00

Split windows horizontally in places that use split to create a new window.

* lisp/tab-bar.el (tab-bar-new-tab-to):
* lisp/window.el (window-state-put):
To create a new window, split horizontally instead of vertically.
Use 'window-safe-min-width' for the SIZE arg of 'split-window'.
(bug#62592)
This commit is contained in:
Juri Linkov 2023-05-19 21:04:50 +03:00
parent 459d08c7fe
commit 8e61d23f71
2 changed files with 3 additions and 2 deletions

View File

@ -1568,7 +1568,8 @@ After the tab is created, the hooks in
(window-state-put (window-state-get)))
;; Create a new window to get rid of old window parameters
;; (e.g. prev/next buffers) of old window.
(split-window) (delete-window))))
(split-window nil window-safe-min-width t)
(delete-window))))
(let ((buffer
(if (and (functionp tab-bar-new-tab-choice)

View File

@ -6382,7 +6382,7 @@ windows can get as small as `window-safe-min-height' and
(selected-window)))
(delete-other-windows-internal window root)
;; Create a new window to replace the existing one.
(setq window (prog1 (split-window window)
(setq window (prog1 (split-window window window-safe-min-width t)
(delete-window window)))))
(set-window-dedicated-p window nil)