all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Giving values colors
@ 2004-11-06 12:12 JS
  2004-11-08 22:34 ` kgold
  0 siblings, 1 reply; 2+ messages in thread
From: JS @ 2004-11-06 12:12 UTC (permalink / raw)


When I define a val in emacs:

val temp = 23;

is there someway to give the word "temp" a color like fun, let, if, then,
else...etc.

Johs

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

* Re: Giving values colors
  2004-11-06 12:12 Giving values colors JS
@ 2004-11-08 22:34 ` kgold
  0 siblings, 0 replies; 2+ messages in thread
From: kgold @ 2004-11-08 22:34 UTC (permalink / raw)


JS <asd@asd.com> writes:
> When I define a val in emacs:
> 
> val temp = 23;
> 
> is there someway to give the word "temp" a color like fun, let, if, then,
> else...etc.

Is the color assigned because
1- it's a variable?
2- it's the string of characters t-e-m-p?

For (2), try a variation of this:

(font-lock-add-keywords 'c-mode
			'(("\\<\\(FIXME\\|XXX\\)" 1 font-lock-warning-face prepend)))
(font-lock-add-keywords 'c-mode
			'(("\\<\\(NOTE\\|XXX\\)" 1 font-lock-constant-face prepend)))

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

end of thread, other threads:[~2004-11-08 22:34 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-11-06 12:12 Giving values colors JS
2004-11-08 22:34 ` kgold

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.