all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Could the current font-lock mechanism support font locking code in comments?
@ 2021-03-30  7:40 scame
  2021-03-30 14:06 ` Stefan Monnier
  0 siblings, 1 reply; 9+ messages in thread
From: scame @ 2021-03-30  7:40 UTC (permalink / raw)
  To: emacs-devel@gnu.org

For example, if I have a file which have some
commented code parts then they could be easier to
read if they were also font locked maybe with dimmed
versions of the regular font lock colors.

Could it be done by reusing the current font locking
implementation and re-running it on a commented code part?

I mean something like layers, the comment is font locked
first with comment syntax as usual and then if some option
is set then font locking is run again on the comment contents
like it's some individual file and it's fontified with dimmed
colors, so it can be distinguished from regular code.

Could current font lock support this somehow or there
is no way that the same buffer part can be fontified
two times by such competing rules?



^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2021-03-31  4:38 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-03-30  7:40 Could the current font-lock mechanism support font locking code in comments? scame
2021-03-30 14:06 ` Stefan Monnier
2021-03-30 15:44   ` scame
2021-03-30 16:18     ` Stefan Monnier
2021-03-30 18:09       ` [External] : " Drew Adams
2021-03-31  0:10         ` Arthur Miller
2021-03-31  1:12         ` Stefan Monnier
2021-03-31  4:36           ` Drew Adams
2021-03-31  4:38             ` Drew Adams

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.