For efficiency, we recommend writing these functions so that they
usually assign faces to around 400 to 600 characters at each call.
+
+When the buffer text includes very long lines, these functions are
+called with the buffer narrowed to a relatively small region around
+@var{pos}, and with narrowing locked, so the functions cannot use
+@code{widen} to gain access to the rest of the buffer.
+@xref{Narrowing}.
@end defvar
@node Basic Faces
* Changes in Emacs 29.1
---
-** Emacs is now capable of editing files with arbitrarily long lines.
-The display of long lines has been optimized, and Emacs no longer
-chokes when a buffer on display contains long lines. If you still
-experience slowdowns while editing files with long lines, this is due
-either to the current major mode or one of the enabled minor modes, in
-which case you should open the the file with M-x find-file-literally
-instead of C-x C-f, or to truncation of long lines, which you can
-disable with C-x x t. The buffer may also be occasionally
-mis-fontified. The variable 'long-line-threshold' controls whether
-and when these display optimizations are used.
+** Emacs is now capable of editing files with very long lines.
+The display of long lines has been optimized, and Emacs should no
+longer choke when a buffer on display contains long lines. The
+variable 'long-line-threshold' controls whether and when these display
+optimizations are in effect.
+
+If you still experience slowdowns while editing files with long lines,
+this is due either to the current major mode or to one of the enabled
+minor modes. Try disabling the minor modes, or turn on 'so-long-mode'
+or 'so-long-minor-mode', or visit the file with find-file-literally'
+instead of the usual 'C-x C-f'. Another reason for slowdown could be
+line truncation, which you can turn off with 'C-x x t'.
+
+Note that the display optimizations in these cases may cause the
+buffer to be occasionally mis-fontified.
+++
** New command to change the font size globally.
+++
** New argument LOCK of 'narrow-to-region'.
-When 'narrow-to-region' is called from Lisp with the optional third
-argument LOCK non-nil, calls to 'widen', or to 'narrow-to-region' with
-an optional argument LOCK nil, do not produce any effect until the end
-of the current body form.
+If 'narrow-to-region' is called from Lisp with the new optional
+argument LOCK non-nil, then calls to 'widen' and calls to
+'narrow-to-region' with the optional argument LOCK nil or omitted do
+not produce any effect until the end of the current body form.
** Themes
doc: /* List of functions to call to fontify regions of text.
Each function is called with one argument POS. Functions must
fontify a region starting at POS in the current buffer, and give
-fontified regions the property `fontified'.
+fontified regions the property `fontified' with a non-nil value.
Note that, when the buffer contains one or more lines whose length is
-above `long-line-threshold', the restrictions of the buffer are locked
+above `long-line-threshold', the narrowing of the buffer is locked
(see `narrow-to-region'), and these functions only have access to a
-small portion of the buffer around POS. */);
+small portion of the buffer around POS and cannot use `widen' to gain
+access to other portions of buffer text. */);
Vfontification_functions = Qnil;
Fmake_variable_buffer_local (Qfontification_functions);