Re: conditional highlight (without losing other definitions)
Federico Bruni <[email protected]> Thu, 23 Feb 2012 00:05:13 +0100
| Newsgroups | gmane.comp.gnu.source-highlight.general |
|---|---|
| Message-ID | <[email protected]> |
Il 22/02/2012 10:42, Lorenzo Bettini ha scritto:
> If I remember correctly, you can create a variable for the single
> delimiter and then use the variable twice (in your case), for instance
> (not tested)
>
> vardef STRING = "\""
> string delim $STRING $STRING multiline
>
> using
>
> vardef STRING = '".*"'
>
> will not let you use the environment mechanisms and will surely eagerly
> try to match everything till it finds another "
I was interested in variables because I wanted to type less.
The variable above is useless for me.
And I've just realized that I can't use variables for environment
definitions, which is what I would really need to "shorten".
For example:
environment scheme delim '#\'?\(' ")" multiline nested begin
environment scheme delim "(" ")" multiline nested begin
include "url.lang"
end
environment string delim "\"" "\"" multiline begin
include "url.lang"
end
end
I think I'll go back and use the list.
Thanks anyway for your advices,
Federico