Re: [Emacs-diffs] emacs/src xdisp.c

View: New views
2 Messages — Rating Filter:   Alert me  

Parent Message unknown Re: [Emacs-diffs] emacs/src xdisp.c

by Eli Zaretskii :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I believe the first paragraph below should not be deleted:

>  -   You will find a lot of redisplay optimizations when you start
>  -   looking at the innards of redisplay.  The overall goal of all these
>  -   optimizations is to make redisplay fast because it is done
>  -   frequently.
>  -
>  -   Two optimizations are not found in xdisp.c.  These are the direct
>  -   operations mentioned above.  As the name suggests they follow a
>  -   different principle than the rest of redisplay.  Instead of
>  -   building a desired matrix and then comparing it with the current
>  -   display, they perform their actions directly on the display and on
>  -   the current matrix.
>  -
>  -   One direct operation updates the display after one character has
>  -   been entered.  The other one moves the cursor by one position
>  -   forward or backward.  You find these functions under the names
>  -   `direct_output_for_insert' and `direct_output_forward_char' in
>  -   dispnew.c.

Even if we get rid of the `direct_output_*' functions, there will be
still ``a lot of optimizations'' left in xdisp.c, and the comment
should mention that, because anyone who hacks the display engine
should know about that possibility.  If necessary, I'm prepared to add
a list of these optimizations with short descriptions.

I also question the decision to remove the comment about the
`direct_output_*' without actually removing the code (apologies if I
missed the latter).  It's not like we are documenting a feature we
don't want to use: it's already used.  As long as the code is there,
hacking redisplay without knowing about them is at best not wise.



Re: [Emacs-diffs] emacs/src xdisp.c

by Stefan Monnier :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

> I believe the first paragraph below should not be deleted:

AFAIK it's not deleted.

It looks like I wasn't quick enough to uncommit my mistake and you got
the intermediate state (rev 1.1317 of xdisp.c, which doesn't exist any
more in the CVS).


        Stefan