[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#44469: 27.1; Fontlock markup disappers when visual line is active
From: |
Eli Zaretskii |
Subject: |
bug#44469: 27.1; Fontlock markup disappers when visual line is active |
Date: |
Thu, 05 Nov 2020 17:45:08 +0200 |
> From: YH Tan <astyh83@gmail.com>
> Date: Thu, 5 Nov 2020 16:19:18 +0800
>
> I have the following setting in my `.emacs.d` folder.
>
> ```
> (defface org-commentary
> '((t :foreground "tan1"))
> "Face for commentary text in org mode")
>
> (defface org-commentary-delimiter
> '((t :foreground "tan4"))
> "Face for commentary text delimiter in org mode")
>
> (defun org-add-my-extra-markup ()
> (add-to-list 'org-font-lock-extra-keywords
> `(,(rx (group "{{")
> (group (+? anything))
> (group "}}"))
> (1 '(face org-commentary-delimiter)) ;; use '(face default
> invisible t) to make invisible
> (2 '(face org-commentary))
> (3 '(face org-commentary-delimiter)))))
>
> (add-hook 'org-font-lock-set-keywords-hook #'org-add-my-extra-markup)
> ```
>
> As can be seen in the sample org document below, syntax highlighting is
> unstable for the Chinese text - color disappers when the visual line is
> selected.
Could be bug#43363. Can you try the latest emacs-27 branch of the
Emacs Git repository?