emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/org-superstar 82440ccda4 155/162: Avoid empty font-lock ke


From: Stefan Kangas
Subject: [nongnu] elpa/org-superstar 82440ccda4 155/162: Avoid empty font-lock keyword if inlinetask first bullet is not used
Date: Fri, 31 Dec 2021 19:35:40 -0500 (EST)

branch: elpa/org-superstar
commit 82440ccda498e92ba9cc1f798ec92b4c4064eef1
Author: Anders Johansson <mejlaandersj@gmail.com>
Commit: Anders Johansson <mejlaandersj@gmail.com>

    Avoid empty font-lock keyword if inlinetask first bullet is not used
    
    When the inlinetask first bullet should not be shown, the match regexp for
    that keyword shouldn’t be added to font-lock-keywords.
    
    Previously, this last keyword got converted to:
    ("^\\(?4:\\*\\)\\(?:\\*\\{2,\\}\\) " (0 nil))
    
    When keywords were compiled. This appears to have done no harm except
    unnecessary searches in fontification.
---
 org-superstar.el | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/org-superstar.el b/org-superstar.el
index e52dd33e0e..73b32a3f3d 100644
--- a/org-superstar.el
+++ b/org-superstar.el
@@ -851,11 +851,11 @@ cleanup routines."
            ,@(when (featurep 'org-inlinetask)
                '((2 (org-superstar--prettify-other-hbullet)
                     prepend))))
-          ("^\\(?4:\\*\\)\\(?:\\*\\{2,\\}\\) "
-           ,@(when (and (featurep 'org-inlinetask)
-                        org-inlinetask-show-first-star
-                        (not org-superstar-remove-leading-stars))
-               '((4 (org-superstar--prettify-first-bullet)
+          ,@(when (and (featurep 'org-inlinetask)
+                       org-inlinetask-show-first-star
+                       (not org-superstar-remove-leading-stars))
+              '(("^\\(?4:\\*\\)\\(?:\\*\\{2,\\}\\) "
+                 (4 (org-superstar--prettify-first-bullet)
                     t)))))))
 
 (defun org-superstar--fontify-buffer ()



reply via email to

[Prev in Thread] Current Thread [Next in Thread]