diff options
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/font-lock.el | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/lisp/font-lock.el b/lisp/font-lock.el index ceadcf19728..2a050c9637e 100644 --- a/lisp/font-lock.el +++ b/lisp/font-lock.el | |||
| @@ -292,6 +292,12 @@ If a number, only buffers greater than this size have fontification messages." | |||
| 292 | (other :tag "always" t) | 292 | (other :tag "always" t) |
| 293 | (integer :tag "size")) | 293 | (integer :tag "size")) |
| 294 | :group 'font-lock) | 294 | :group 'font-lock) |
| 295 | |||
| 296 | (defcustom font-lock-lines-before 1 | ||
| 297 | "*Number of lines before the changed text to include in refontification." | ||
| 298 | :type 'integer | ||
| 299 | :group 'font-lock | ||
| 300 | :version "22.1") | ||
| 295 | 301 | ||
| 296 | 302 | ||
| 297 | ;; Originally these variable values were face names such as `bold' etc. | 303 | ;; Originally these variable values were face names such as `bold' etc. |
| @@ -1062,7 +1068,8 @@ what properties to clear before refontifying a region.") | |||
| 1062 | (save-match-data | 1068 | (save-match-data |
| 1063 | ;; Rescan between start of lines enclosing the region. | 1069 | ;; Rescan between start of lines enclosing the region. |
| 1064 | (font-lock-fontify-region | 1070 | (font-lock-fontify-region |
| 1065 | (progn (goto-char beg) (beginning-of-line) (point)) | 1071 | (progn (goto-char beg) |
| 1072 | (forward-line (- font-lock-lines-before)) (point)) | ||
| 1066 | (progn (goto-char end) (forward-line 1) (point))))))) | 1073 | (progn (goto-char end) (forward-line 1) (point))))))) |
| 1067 | 1074 | ||
| 1068 | (defun font-lock-fontify-block (&optional arg) | 1075 | (defun font-lock-fontify-block (&optional arg) |