[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: define multi-line comments

From: David Hansen
Subject: Re: define multi-line comments
Date: Fri, 20 Jun 2008 18:01:06 +0200
User-agent: Gnus/5.110011 (No Gnus v0.11) Emacs/23.0.60 (gnu/linux)

On Fri, 20 Jun 2008 16:46:37 +0200 henry atting wrote:

> I have my own text mode (derived from text-mode), which defines some
> syntax highlighting. Defining keywords is no problem but as far as I see
> keywords don't work on serveral lines, e.g. this
>          (list "\".*\"" 0 'font-lock-variable-name-face t) 
> only highlights words or phrases till the line break.
> Can anyone give me a hint how to get it work multi-line.

There are some words about this in the Elisp manual, lookup
`font-lock-multiline'.  But this is incredible complicated.

Good luck ;p

But in many circumstances you can use `font-lock-syntactic-keywords' to
make some region a "string" or "comment" and then use
`font-lock-syntactic-face-function' to give it another face.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]