diff options
| author | Yuan Fu | 2024-05-08 20:27:12 -0700 |
|---|---|---|
| committer | Yuan Fu | 2024-05-08 20:36:36 -0700 |
| commit | 03d4b96da62fbb7abfb7fa8fcfc963313e394f22 (patch) | |
| tree | 62718fa529657aacbc3580b8188cc8cbc0c73d6f | |
| parent | 86187d43e2db841f8ca2893a31f05669f4a1247b (diff) | |
| download | emacs-03d4b96da62fbb7abfb7fa8fcfc963313e394f22.tar.gz emacs-03d4b96da62fbb7abfb7fa8fcfc963313e394f22.zip | |
Fontify doc comment in c-ts-mode with doc-face
* lisp/progmodes/c-ts-mode.el (c-ts-mode--font-lock-settings): Add
rule for /** comments.
| -rw-r--r-- | lisp/progmodes/c-ts-mode.el | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lisp/progmodes/c-ts-mode.el b/lisp/progmodes/c-ts-mode.el index a1b2b1f500c..2d431d75d21 100644 --- a/lisp/progmodes/c-ts-mode.el +++ b/lisp/progmodes/c-ts-mode.el | |||
| @@ -597,8 +597,9 @@ MODE is either `c' or `cpp'." | |||
| 597 | (treesit-font-lock-rules | 597 | (treesit-font-lock-rules |
| 598 | :language mode | 598 | :language mode |
| 599 | :feature 'comment | 599 | :feature 'comment |
| 600 | `((comment) @font-lock-comment-face | 600 | `(((comment) @font-lock-doc-face |
| 601 | (comment) @contextual) | 601 | (:match ,(rx bos "/**") @font-lock-doc-face)) |
| 602 | (comment) @font-lock-comment-face) | ||
| 602 | 603 | ||
| 603 | :language mode | 604 | :language mode |
| 604 | :feature 'preprocessor | 605 | :feature 'preprocessor |