>>>> "TC" == Tim Connors
<tconnors(a)astro.swin.edu.au> writes:
> I tried this:
>
> (setq c++-font-lock-keywords
> (append c++-font-lock-keywords
> (list '(".*foreach.*" 1 font-lock-keyword-face t))))
>
TC> Where you by chance getting a "fontifying blah.c... aborted.aborted."
TC> message in the modeline?
No. I get no error messages. The new kywork simply does not fontify.
TC> Try putting brackets around the (1 font-lock-keyword-face t) list.
TC> So I have now in one of mine:
TC> (setq font-lock-keywords
TC> (append font-lock-keywords
TC> (list
TC>
'("\\<\\(d?a?\\(cos\\|sin\\|tan\\|tan\\|tan2\\)\\(deg\\)?\\|d?\\(sqrt\\|sqr\\|exp\\|abs\\|int\\|nint\\|min\\|max\\|sign\\|log\\|log10\\)\\)h?\\>"
TC> (0 font-lock-math-face append)))))
TC> )
Looking again at how existing keywords (e.g., 'for', 'while') I tried the
following:
(setq c++-font-lock-keywords
(append c++-font-lock-keywords
(list '("\\<foreach\\>\\([^a-zA-Z0-9_$]\\|$\\)" 1
font-lock-keyword-face t))))
This still does not work.
--
Jake Colman -- XEmacs Tinkerer