unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Highlighting special comment for prog-mode
@ 2022-09-11 12:53 uzibalqa
  0 siblings, 0 replies; only message in thread
From: uzibalqa @ 2022-09-11 12:53 UTC (permalink / raw)
  To: uzibalqa via Users list for the GNU Emacs text editor

I have the following code that highlights lines made from semicolons in the case of lisp-interaction-mode.  

(defface special-comment '((t (:background "orange"))))

(font-lock-add-keywords 'lisp-interaction-mode '(("^\\s<\\s<\\s<+$" 0 'special-comment t)))

But whilst trying to extend this to prog-mode, the highlighting is not taking effect.

(font-lock-add-keywords 'prog-mode '(("^\\s<\\s<\\s<+$" 0 'special-comment t)))





^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-09-11 12:53 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-09-11 12:53 Highlighting special comment for prog-mode uzibalqa

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).