jEdit Community - Resources for users of the jEdit Text Editor
Highlighting only between brackets?
Submitted by Anonymous on Monday, 20 September, 2004 - 13:10
Hello,
I wonder if it is possible to restrict literal highlighting to
space between brackets.

I tried to solve my problem with reg-expressions but it
did not work.

example:
In the following lines I want to apply the literal
highlighting (everything between ' and ' should be highlighted)
within the brackets:
options = ('option1 ', 'option2 ', 'option3 ', parameter)
matrix = [ 'sting1' ; 'string2' ]
But I do NOT want to have the highlighting applied in lines like this:
result = a'*b/c'

Does anybody has an idea how to solve this problem?
Is there a simple way to apply literal highlighting only
within brackets? To nest span rules?

Thanks a lot
Comment viewing options
Select your preferred way to display the comments and click 'Save settings' to activate your changes.
Maybe this help to your
by Anonymous on Tue, 21/09/2004 - 13:01
Try this:

<SPAN TYPE="LITERAL1" AT_WORD_START="TRUE">
    <BEGIN>'</BEGIN>
    <END>'</END>
</SPAN>
__
Regards, Skalex.
 
Thanks - this did the job
by Anonymous on Tue, 21/09/2004 - 13:57
Thanks a lot, Skalex.
Indeed the option AT_WORD_START lead to the required effect.
It even works in cases like that:
matrix = [' string','24 teststring','**commentstring']
something I didn't expect to work, because of the naming of
the option. Perhaps NOT_AT_WORD_END would be a better name
for the option?
Best regards
User login
Browse archives
« April 2024  
MoTuWeThFrSaSu
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
 
Poll
Are you interested in language packs for jEdit?
Yes, and I could help maintain translations
26%
Yes, I'd like to have translations
32%
Indifferent
35%
No, that'd be bad (please comment)
7%
Total votes: 1093
Syndication
file   ver   dls
German Localization light   4.4.2.1   82349
Context Free Art (*.cfdg)   0.31   46055
BBEdit scheme   1.0   18595
JBuilder scheme   .001   18495
ColdFusion scheme   1.0   18024
R Edit Mode - extensive version   0.1   17473
Advanced HTML edit mode   1.0   16206
Matlab Edit Mode   1.0   16068
jEdit XP icons   1.0   15229
XP icons for jEdit   1.1   14293