Subject: Re: bug#64596: 30.0.50; On FIXME: in src/buffer.c:1481 (force-mode-line-update)

From: Ihor Radchenko <[email-masked]>
Date: Sun, 16 Jul 2023 08:40:38 +0000

martin rudalics <[email-masked]> writes:

> Here 'set-window-configuration' should be able to tell redisplay that it
> should redisplay the window but it should be able to tell that iff the
> fringe really changed which is fairly easy to find out.  Once it found
> out, which kind of flag would it set?

May someone list all the possible displayed elements Emacs considers?

I think that it might be a good new API to have a single function that
marks things for redisplay. That function will accept arguments
indicating what exactly may need to be redisplayed: CURRENT_TEXT_LINE,
FRINGE, LINE_NUMBERS, CURRENT_BUFFER_TEXT, CURRENT_BUFFER_MODELINES,
ALL_MODELINES, CURRENT_FRAME, etc.

Then, every place where we request redisplay will call that single API
function, while being very explicit what kind of redisplay it has in
mind.

That API function may be implemented in backwards-compatible way - we
can just hide the existing logic inside for now and simplify later
instead of directly manipulating global and local flag variables.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>