I'm writing a VSCode extension to add syntax highlighting to .gabc
files. I would like to match GABC and NABC sections within the code (so I can apply different patterns for each section), as follows:
(GABC section|NABC section)
(GABC section|NABC section|GABC section|NABC section|...)
Concrete example:
(c3) Ad(f|ta) te,(h|vi) Dó(hi|pe)mi(i|vi)ne,(i|vi) *(,)
le(i|vi)vá(i|vi)vi(h|ta) á(ij|pe)ni(h|ta)mam(ij>|pe>) me(i|ta)am:(i|ta) (;)
ve(f|talsi7)ni,(i|vi) et(h|vi) é(g|vi)ri(f|vi)pe(e|ta) me,(fe__|cl-) (,)
Dó(d|ta)mi(e|vi)ne,(f|vi) ad(gxg|////vi) te(h|vi)
<nlba>con(gxg|////vi)fú(f|ta)gi.</nlba>(f|ta) (::i+)
How could I write TexMate rules to match those GABC sections
and NABC sections
within the parentheses?
I'm writing a VSCode extension to add syntax highlighting to .gabc
files. I would like to match GABC and NABC sections within the code (so I can apply different patterns for each section), as follows:
(GABC section|NABC section)
(GABC section|NABC section|GABC section|NABC section|...)
Concrete example:
(c3) Ad(f|ta) te,(h|vi) Dó(hi|pe)mi(i|vi)ne,(i|vi) *(,)
le(i|vi)vá(i|vi)vi(h|ta) á(ij|pe)ni(h|ta)mam(ij>|pe>) me(i|ta)am:(i|ta) (;)
ve(f|talsi7)ni,(i|vi) et(h|vi) é(g|vi)ri(f|vi)pe(e|ta) me,(fe__|cl-) (,)
Dó(d|ta)mi(e|vi)ne,(f|vi) ad(gxg|////vi) te(h|vi)
<nlba>con(gxg|////vi)fú(f|ta)gi.</nlba>(f|ta) (::i+)
How could I write TexMate rules to match those GABC sections
and NABC sections
within the parentheses?
I'm not sure the exact intention
Are you wanting to scope/colour the capture groups separatory?
You can use "captures"
to target a capture group
do you have an example of a file you've trying to tokenize?