[TxMt] Nested snippet placeholders

Allan Odgaard allan at macromates.com
Thu Jan 27 13:04:42 UTC 2005


On Jan 26, 2005, at 15:53, Jan-Ole Esleben wrote:

> Apparently, at the moment, snippets are processed by regular
> expression matching

No they are not, but anyway... ;)

> [...] wouldn't it be great if one could do something like this (that's 
> for Prolog code):
>
> findall(${1:X}, ${2:member(${1:X}, $4)}, ${1:X}s)
>
> If you deleted $2, of course, the placeholders inside it would not be
> activated any more.

What if you delete $2 and back-tab to $1?

The thing Justin Blake wants (about starting new snippets inside 
snippets) is on the to-do, when I get to that, I'll consider this one 
as well. There is some improvements I'd like to make, for example I'd 
like to be able to filter a mirror-typing (e.g. the “wrap in tag” 
snippet should not show tag arguments for the close tag), so I may end 
up with a more general system than currently (which should be good :) 
).




More information about the textmate mailing list