all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* `font-lock-add-keywords' works... sometimes
@ 2019-03-19  7:26 Emanuel Berg
  2019-03-19 14:42 ` Michael Heerdegen
  2019-03-19 16:44 ` Stefan Monnier
  0 siblings, 2 replies; 10+ messages in thread
From: Emanuel Berg @ 2019-03-19  7:26 UTC (permalink / raw)
  To: help-gnu-emacs

It is pretty cool to have Emacs as
psychedelic/LSD-ish as possible. For example,
when one types the name of a color, that word
becomes that color!

Or when one types the name of a face, that name
becomes the color of the face! (This is not
only cool but also practical BTW.)
Screenshot:
  http://user.it.uu.se/~embe8573/figures/emacs/emacs-lisp-faces.png [1]

Or even better/worse, when one types the word
of a sound, that will play from a directory of
audio files, finding a file with the same name
(e.g. "wolf" triggers "wolf.mp3") - this will
*freak you out* when deep in concentration and
not expecting it in the least! Try it... if you
dare :)

But anyway...

Why does this work

    (font-lock-add-keywords 'message-mode
     '(
       ("yellow" . font-lock-function-name-face)
      )
     t) ; append [2]

but not this

    (font-lock-add-keywords 'text-mode
     '(
       ("yellow" . font-lock-function-name-face)
      )
     t) ; append [3]

?

TIA


[1] line 20 @ http://user.it.uu.se/~embe8573/emacs-init/faces.el
[2] line 99 @ http://user.it.uu.se/~embe8573/emacs-init/gnus/message-my.el
[3] line  9 @ http://user.it.uu.se/~embe8573/emacs-init/my-text.el

-- 
underground experts united
http://user.it.uu.se/~embe8573




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

end of thread, other threads:[~2019-03-21 14:25 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-03-19  7:26 `font-lock-add-keywords' works... sometimes Emanuel Berg
2019-03-19 14:42 ` Michael Heerdegen
2019-03-19 16:51   ` Emanuel Berg
2019-03-19 22:22     ` Michael Heerdegen
2019-03-19 23:37       ` Emanuel Berg
2019-03-20  6:22       ` Eli Zaretskii
2019-03-21 14:25         ` Emanuel Berg
2019-03-19 16:44 ` Stefan Monnier
2019-03-19 17:04   ` Emanuel Berg
2019-03-19 22:09   ` Michael Heerdegen

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.