* Eli Zaretskii (2005-04-15) writes: >> From: Ralf Angeli <[EMAIL PROTECTED]> >> Date: Thu, 14 Apr 2005 13:25:27 +0200 >> >> A worse annoyance of stealth fontification is that this happens >> again and again after every modification of the buffer. > > In practice, such re-fontification ends very quickly. So I don't > understand why it is an annoyance for you; can you give a specific > example?
I mostly seeing this in large LaTeX files. As an example, create a new .tex file and copy the following lines repeatedly without blank lines in between into the buffer until you have, say, 10.000 lines: \newcommand{\mycontent}{\ensuremath{\lambda_{1}}}% \begin{itemize}% \item \begin{align*}% \left\{ \begin{array}{l} b_{c} \text{some long line with $\mycontent$} \end{array} \right\} \end{align*}% \end{itemize}% If you want to test this in clean room conditions, save the file, start an Emacs instance with `emacs -Q', open the file, type `M-x font-lock-mode RET' and wait. It's good to have something handy for monitoring the CPU usage, e.g. top or the CPU meter of GKrellM. Now wait for a few seconds until the initial stealth fontification starts. You should see that CPU usage is growing until the whole buffer is fontified. In order to see the effect of re-fontification after a change (which is done only from the point of change downwards and not for the whole buffer as already mentioned in the reply to Richard), insert a random character somewhere at the start of the buffer and wait again until stealth fontification starts. This second fontification pass takes nearly as long as the first because of the change in the buffer happening near its top. -- Ralf _______________________________________________ Emacs-devel mailing list Emacs-devel@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-devel