emacs-devel
[Top][All Lists]
Advanced

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

Re: Add function to rotate/transpose all windows


From: martin rudalics
Subject: Re: Add function to rotate/transpose all windows
Date: Tue, 12 Nov 2024 18:46:16 +0100
User-agent: Mozilla Thunderbird

> Flipping windows won't change the size using the current approach, but
> the window will be split to match it's old height, idk if that will give
> bug or not.  I would rather it just simply doesn't work with fied
> windows, instead of confusing the user who probably doesnt even know
> emacs has fixed windows.

Flipping should preserve the size of all windows automatically.  But
better make sure that it does.

>> With the pixel-tree approach
>> you will have to add it to the pixel tree and get one "a" more in the
>> ca..rs you use for accessing the tree's elements.
>
> wdym by the last sentence?

After you deleted the other windows you can no more access properties of
the deleted windows like their parent, combination-limit, size,
fixed-sizeness, atomicity and other properties.  So IIUC you have to
store all these in the pixel-tree and access them from there.  This
means that you will probably need more deeply nested cadr, caadr, caddr
or nth calls to access those elements in the pixel trees.

> Also, the only thing I'm checking for is if a window is atomic and fixed
> size, right?
>
> to check the fixed size, I'll just use window-fixed-size-p,

It's 'window-size-fixed-p' and it does not work for windows that have
been deleted.  'window-fixed-size-p' consults only the buffer-local
value of the variable 'window-size-fixed' for a window's buffer.  It's
used in 'balance-windows-area' only.

> and to check
> if atomic (window-parameter window 'window-atom).

Yes.

martin



reply via email to

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