Hmn. Good point - I'm really not used to Velocity at all; I'm a Rails and PHP developer at heart. New job meant a move to Java, and we use Velocity to template sites.
To be specific, my current bundle is called HTML(Velocity). The best example perhaps for doing what you suggest is the HTML(Rails) bundle: it essentially describes the Rails template delineators, and then says "when you're in scope html.text.rails, inherit all your highlighting from the ruby bundle".
So it'd definitely be possible.
Right now, my main use case is HTML(Velocity), so I'm going to stick to that, and then see if it can be abstracted out. Velocity seem to be really rather limited in functionality, so it's more a case of getting the scoping and highlighting right, rather than coping with endless method names. And no, I have no plans to autocomplete methods on objects (yet).
Advice from other bundle developers would definitely be welcome, incidentally; I've never really done this before, but it doesn't appear to be so hard...
t.
On 14/07/06, Brian Lalor blalor@bravo5.org wrote:
On Jul 14, 2006, at 5:44 AM, Tom Armitage wrote:
It also inherits all the HTML highlighting/functionality, obviously.
I think it's great that you're implementing this bundle! I recently did some work with Velocity, but it wasn't for generating HTML. I'm not sure how one would go about implementing a bundle that reuses the same grammar in multiple scopes, but that might be worth looking into here. Perhaps a Velocity-HTML language and a Velocity-Plain Text language?
Personally, I'd much prefer to use XSL-T for generating HTML than using Velocity, but sometimes it's a necessary evil...
-- Brian Lalor blalor@bravo5.org
For new threads USE THIS: textmate@lists.macromates.com (threading gets destroyed and the universe will collapse if you don't) http://lists.macromates.com/mailman/listinfo/textmate