[SVN] Adding ZPT scope to the HTML Bundle ok?

Tom Lazar tom at tomster.org
Mon Feb 5 13:18:10 UTC 2007


On 04.02.2007, at 09:07, Michael Sheets wrote:

> Work with the scope system, not against it. ;)

good point, i'll try to keep it in mind ;-)

> ZPT isn't all that different from the many other template languages  
> Textmate supports, all of them use text.html.<lang> for the root  
> scope. Yes it might be that the template language can do other  
> things… but likely it's mostly for HTML no? We've got likely what 25 
> + html-ish template languages now, if each one got to add things to  
> the html bundle it'd be a mess.

that's interesting and sounds good. giving ZPT the `text.html.zpt`  
scope certainly enables all the nifty niceties of the HTML bundle,  
however, one thing i particularly miss now is the neat colouring of  
invalid/illegal XML.

> If it absolutely can't be done any other way you could have two  
> root scopes (surround the whole grammar in a rule), but really I  
> doubt that's needed.

that sounds interesting, but i'm really unsure, how to go about this.  
wouldn't the surrounding rule also need a name? if you could provide  
rough sketch of how that rule should look, that would be great.

alternatively, i could look at how the XML bundle implements the  
scoping of illegal xml and attempt to add it the html bundle (for  
XHTML).

thanks for your elaborate response, looking forward to more ;-)

cheers,

tom

>
> And of course I always sound negative when I hammer in the scope  
> system, which is not how I try to come off but. ;) Really great to  
> see new languages added to the repository so fast. Was amazing at  
> Macworld to look into the bundles directory and see 143 bundles,  
> and more added since then!
> _______________________________________________
> textmate-dev mailing list
> textmate-dev at lists.macromates.com
> http://lists.macromates.com/mailman/listinfo/textmate-dev
>
>




More information about the textmate-dev mailing list