org.el: Avoid repeated calls in org-font-lock-add-priority-faces
* lisp/org.el (org-font-lock-add-priority-faces): Let-bind bounds to avoid repeated calls. This will also make the conflict resolution in the next merge of maint clearer.
This commit is contained in:
parent
1f1644396b
commit
ba6cf4645f
15
lisp/org.el
15
lisp/org.el
|
@ -5845,13 +5845,14 @@ If TAG is a number, get the corresponding match group."
|
||||||
(defun org-font-lock-add-priority-faces (limit)
|
(defun org-font-lock-add-priority-faces (limit)
|
||||||
"Add the special priority faces."
|
"Add the special priority faces."
|
||||||
(while (re-search-forward org-priority-regexp limit t)
|
(while (re-search-forward org-priority-regexp limit t)
|
||||||
(add-face-text-property
|
(let ((beg (match-beginning 1))
|
||||||
(match-beginning 1)
|
(end (match-end 1)))
|
||||||
(match-end 1)
|
(add-face-text-property
|
||||||
(org-get-priority-face (string-to-char (match-string 2))))
|
beg end
|
||||||
(add-text-properties
|
(org-get-priority-face (string-to-char (match-string 2))))
|
||||||
(match-beginning 1) (match-end 1)
|
(add-text-properties
|
||||||
(list 'font-lock-fontified t))))
|
beg end
|
||||||
|
(list 'font-lock-fontified t)))))
|
||||||
|
|
||||||
(defun org-font-lock-add-tag-faces (limit)
|
(defun org-font-lock-add-tag-faces (limit)
|
||||||
"Add the special tag faces."
|
"Add the special tag faces."
|
||||||
|
|
Loading…
Reference in New Issue