bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#32825: 27.0.50; Deterministic window management


From: Juri Linkov
Subject: bug#32825: 27.0.50; Deterministic window management
Date: Wed, 07 Nov 2018 23:55:14 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu)

>> Isn't this bad that this function does the double work, i.e.
>> first displays the buffer, then reverts, and if everything is right,
>> displays the same buffer again.  Shouldn't it display the buffer
>> only once, then check if everything is right, and revert only
>> if not.
>
> The primal problem this was supposed to solve is:
>
> (1) Get the size (typically the body width) of the window supposed to
>     display a buffer (typically a doc or man buffer).
>
> (2) Format the buffer in some way so that it fits into (1)'s size.
>
> (3) Call 'display-buffer' to actually display the buffer.

This is why man.el currently uses a simpler solution:

(1) Call 'display-buffer' to display the buffer.

(2) Format the buffer in some way so that it fits into displayed size.

> We obviously could use this approach to revert 'display-buffer'
> whenever it did something bad.  But we shouldn't do that by default,
> the overhead for storing the configurations is not negligible.

When a man page is not found, currently it reverts 'display-buffer'.

What benefits would be provided by the approach that uses
'display-buffer-try-and-revert'?





reply via email to

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