[TxMt] Re: Restrict characters in multiline strings

Jacob Carlborg doob at me.com
Sun Nov 1 20:35:41 UTC 2015


On 2015-11-01 20:52, Louis Abraham wrote:
> You can use a regular expression with the match key. For example in the
> Python bundle :
> {name = 'constant.numeric.integer.hexadecimal.python';
> match = '\b(?i:(0x\h*))';
> };

Not sure I understand what you mean. The match attribute matches on a 
single line, not across multiple lines. I need to match code like this:

a = x"abc2
13cd";

This is usually handled by using the "begin" and "end" attributes:

{
   begin = 'x"';
   end = '"';
}

But everything in between the double quotes will match.

-- 
/Jacob Carlborg



More information about the textmate mailing list