emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: master 6a2ee981c3: Add new functions for splitting the root window


From: Emanuel Berg
Subject: Re: master 6a2ee981c3: Add new functions for splitting the root window
Date: Tue, 20 Sep 2022 09:47:12 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

Juri Linkov wrote:

>> (defun other-window-or-split ()
>>   (interactive)
>>   (when (one-window-p)
>>     (split-window-below) )
>>   (other-window 1) )
>
> A.k.a. windmove-create-window.

OK, I don't have that ...

>> (defun swap-windows ()
>>   (interactive)
>>   (let ((buffer (current-buffer)))
>>     (other-window 1)
>>     (switch-to-buffer-other-window (current-buffer))
>>     (other-window 1)
>>     (switch-to-buffer buffer) ))
>
> A.k.a. windmove-swap-states.

Same ...

>> (defun window-increase-size (&optional lines)
>>   (interactive "p")
>>   (unless (one-window-p)
>>     (or lines (setq lines 1))
>>     (window-resize nil lines) ))
>>
>> (defun window-decrease-size (&optional lines)
>>   (interactive "p")
>>   (unless (one-window-p)
>>     (or lines (setq lines 1))
>>     (window-resize nil (* -1 lines) )))
>
> It was proposed to add this on 'C-x w r left/right/up/down'

'C-x w' is undefined here, but if you add that (by "this" you
mean the shortcuts?) I'd add it with i, l, i and k instead (or
"as well").

'C-x' is not so ergonomic tho ... I take it 'w' is mnemonic
for "window" and 'r' for "resize", I think that should only be
considered when the keys are good. But they are.

-- 
underground experts united
https://dataswamp.org/~incal




reply via email to

[Prev in Thread] Current Thread [Next in Thread]