[TxMt] feature request: timeout on highlighting

Brian Lalor blalor at bravo5.org
Sat Dec 4 11:13:47 UTC 2004


On Dec 3, 2004, at 9:47 PM, Allan Odgaard wrote:

> Scanning for folding markers OTOH is not lazy, and that's currently  
> the (huge) bottleneck in loading files

That's probably what I'm seeing; that or just the time it takes to load  
a 1.5M file.  Most files I work with are quite a bit smaller.

My XML syntax is here[1], and the folding properties are:
foldingStartMarker = "^\\s*(<[^!?%/](?!.+?/>)|<[!%]--(?!.+?--%?>)|<%[!]?
(?!.+?%>))\\s*$";
foldingStopMarker  = "(</[^?]+?>|[/%]>|-->)\\s*$";

This is supposed to start folds on the following text:
	<!--
	<%--
	<%
	<%!
	<foo>
... but not if the line looks like this:
	<!-- -->
	<%-- --%>
	<% %>
	<%! %>
	<foo />
	<foo></foo>

It's not exactly lightweight; I'd think I'd prefer to see a more  
flexible folding-marker system that would allow me to define pairs of  
start/end markers.  That keep blocks like
	<!--
	--%>
from getting folded.

[1]  
http://telly.bravo5.org/svn/repos/TextMate/trunk/Bundles/XML.tmbundle/ 
Syntaxes/XML.plist

-- 
    __   ____
   / /  / __/ Brian Lalor
  / _ \/__ \  blalor at bravo5.org
/_.__/____/  http://bravo5.org/



More information about the textmate mailing list