help-source-highlight
[Top][All Lists]
Advanced

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

Re: [Help-source-highlight] conditional highlight (without losing other


From: Lorenzo Bettini
Subject: Re: [Help-source-highlight] conditional highlight (without losing other definitions)
Date: Sun, 26 Feb 2012 11:01:33 +0100
User-agent: Mozilla/5.0 (X11; Linux i686; rv:10.0.2) Gecko/20120216 Thunderbird/10.0.2

On 02/26/2012 10:30 AM, Federico Bruni wrote:
I changed my mind again: I prefer the environment, even if it gets huge
(see below).
The only problem is: the delimiters "\markup {" and "}" are not
highlighted: "}" should be highlighted as cbracket and "\markup" same
colour as markup_command.

There's a workaround?

from what I see, the only expression that deals with "\markup {" and "}" is the following one

environment markup delim '\\markup\s*\{' "}" multiline nested begin

thus both strings will be highlighted as markup...


# Markup commands (any \command inside \markup{})
environment markup delim '\\markup\s*\{' "}" multiline nested begin
# definitions I want to preserve in this environment
cbracket = $CBRACKET
string delim "\"" "\"" multiline
comment delim "%{" "%}" multiline nested
comment start "%"
scheme_value = $SCHEME_VALUE
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
# actual definition
markup_command = '\\[[:alpha:]-]+'

# needed for nested blocks inside \markup{}
environment markup delim "{" "}" multiline nested begin
cbracket = $CBRACKET
string delim "\"" "\"" multiline
comment delim "%{" "%}" multiline nested
comment start "%"
scheme_value = $SCHEME_VALUE
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
markup_command = '\\[[:alpha:]-]+'
end
end

_______________________________________________
Help-source-highlight mailing list
address@hidden
https://lists.gnu.org/mailman/listinfo/help-source-highlight


--
Lorenzo Bettini, PhD in Computer Science, DI, Univ. Torino
ICQ# lbetto, 16080134     (GNU/Linux User # 158233)
HOME: http://www.lorenzobettini.it MUSIC: http://www.purplesucker.com
http://www.myspace.com/supertrouperabba
BLOGS: http://tronprog.blogspot.com  http://longlivemusic.blogspot.com
http://www.gnu.org/software/src-highlite
http://www.gnu.org/software/gengetopt
http://www.gnu.org/software/gengen http://doublecpp.sourceforge.net



reply via email to

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