From joost@greenskin.net Wed Oct 6 18:21:13 2004 From: Joost Schuttelaar To: textmate@lists.macromates.com Subject: [TextMate] Tab in snippets Date: Wed, 06 Oct 2004 20:21:09 +0200 Message-ID: <41643795.7090009@greenskin.net> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============7582432805556503588==" --===============7582432805556503588== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Small thingie: I think it would be very convenient if after entering all the parameters in the snippet, the tab key would place the cursor at the end of the snippet. Example: ahref\thttp://somewhere.com/\tsomewhere\t results in somewhereCURSOR instead of somewhere CURSOR :) BTW: I'm starting to enjoy this editor very much...! :) -- Joost Schuttelaar --===============7582432805556503588==-- From cryo@diku.dk Wed Oct 6 18:28:52 2004 From: Sune Foldager To: textmate@lists.macromates.com Subject: Re: [TextMate] Tab in snippets Date: Wed, 06 Oct 2004 20:28:49 +0200 Message-ID: <9147A47D-17C5-11D9-B8BB-000393D4B5C8@diku.dk> In-Reply-To: <41643795.7090009@greenskin.net> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============8480768609101518117==" --===============8480768609101518117== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit On 6/10-2004, at 20:21, Joost Schuttelaar wrote: > Small thingie: I think it would be very convenient if after entering > all the parameters in the snippet, the tab key would place the cursor > at the end of the snippet. I agree, although this is possible of course in the current version like this: $2 Or similar. I believe $0 can also be used for that purpose, regardless of the number of tab stops. I sort of think that this should not be neccesary and it should always end up after the snippet body no matter what... I can't imagine any situation where you _don't_ want that.. ? -- Sune. "Ph'nglui mglw'nafh Cthulhu R'lyeh wgah'nagl fhtagn" --===============8480768609101518117==-- From benny@diku.dk Thu Oct 7 04:42:59 2004 From: Benny =?utf-8?q?Kj=C3=A6r?= Nielsen To: textmate@lists.macromates.com Subject: Re: [TextMate] Tab in snippets Date: Thu, 07 Oct 2004 06:42:57 +0200 Message-ID: In-Reply-To: <9147A47D-17C5-11D9-B8BB-000393D4B5C8@diku.dk> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============3764539628866014249==" --===============3764539628866014249== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit On Wed, 6 Oct 2004, Sune Foldager wrote: > On 6/10-2004, at 20:21, Joost Schuttelaar wrote: > > > Small thingie: I think it would be very convenient if after entering > > all the parameters in the snippet, the tab key would place the cursor > > at the end of the snippet. > > I agree, although this is possible of course in the current version > like this: > $2 > > Or similar. I believe $0 can also be used for that purpose, regardless > of the number of tab stops. I sort of think that this should not be > neccesary and it should always end up after the snippet body no matter > what... I can't imagine any situation where you _don't_ want that.. ? Well, I needed it for a snippet I created for latex to make begin/end constructions such as: \begin{itemize} \end{itemize} Here you want the cursor to end up on a blank line between the two lines of the snippet. Note a really nice TM feature here. If you specify the same placeholder twice ($1 below) then it is filled out simultaneously when using the snippet (this is a documented feature). Really cool ;-) \\begin{$1} $0 \\end{$1} Since it might be a bit annoying to always having to define $0 for snippets simply needing the cursor at the end of the snippet this could simply be interpreted as the default if no $0 placeholder is specified. -- Benny --===============3764539628866014249==-- From timfm@hawaii.rr.com Thu Oct 7 07:39:52 2004 From: timothy martens To: textmate@lists.macromates.com Subject: Re: [TextMate] Tab in snippets Date: Wed, 06 Oct 2004 21:39:30 -1000 Message-ID: <0608F2F2-1834-11D9-BB1D-000A95C0A620@hawaii.rr.com> In-Reply-To: <9147A47D-17C5-11D9-B8BB-000393D4B5C8@diku.dk> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0562428519938777151==" --===============0562428519938777151== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit On Oct 6, 2004, at 8:28 AM, Sune Foldager wrote: > I agree, although this is possible of course in the current version > like this: > $2 Better than that, when the cursor is a "$1" let me click on the image name in the project drawer and have it insert the source/path automatically! Addittionaly, It would be cool to be able o select an image in the project drawer an be able to preview it in the main window (ala skEdit) rather than get garbled ASII --===============0562428519938777151==--