Couple of questions regarding syntaxes:
I'm working on modifying the HTML syntax to support JSP. I've created the following definition for comments; JSP and HTML comments are similar. JSP comments look like <%-- comment --%>. I can use a simple regexp to search for <!-- or <%--, but is there a way to be smarter about how the comment ends? I'd like to make sure an illegal JSP comment gets highlighted as such:
WRONG: <%-- -->
... or maybe ... <%-- --> --%>
I've currently got the (not quite smart enough) pattern: { name = "Comments"; begin = "<[%!]--"; end = "--%?>"; foregroundColor = "red"; },
How is the "include" keyword supposed to work in a pattern? I've tried this: name = "Embedded Java"; backgroundColor = "#E5E5E5"; begin = "<%"; include = "Java"; end = "%>";
... but that only highlights the background of the excursion, not the text within. I've created a Java bundle with "Java" defined in Syntaxes/Java.plist.