Home Download Buy Blog Forum Support

Does ST2 have placeholders?

Does ST2 have placeholders?

Postby sfranky on Fri Sep 30, 2011 10:15 pm

Hi all..
I m not sure that's the proper name, I mean the vim equivalent of <++>.
You put that anywhere you want in your code, and you can jump there with some keybindings... something like $N, but not for snippets!
thanks
sfranky
 
Posts: 96
Joined: Mon Oct 19, 2009 10:06 pm

Re: Does ST2 have placeholders?

Postby DSHugo on Sat Oct 01, 2011 8:21 am

I'm not exactly sure of what you actually need, but there are bookmarks that sound about right for you: ctrl+f2 to set one, f2 and shift+f2 to navigate. One can have several bookmarks at one line, attached to selections, etc. They are not stored if you close and then reopen the file, but are stored across ST2 relaunches.
If you would actually want to navigate through some kind of fixed-form "hard" placeholders (if they are literally just a symbol sequence within the text) on every file you open, you'd probably have to make a small plugin to call the search command for that symbol sequence, and attach a key binding.
DSHugo
 
Posts: 42
Joined: Tue Sep 20, 2011 11:05 am

Re: Does ST2 have placeholders?

Postby sfranky on Sat Oct 01, 2011 8:34 am

Bookmarks are not convenient because there is no visual cue as to *exactly* where in the line the placeholder is. And also what you said, that they are not retainable.
The second suggestion is what I really need, but unfortunately, I don't know how to program :(
thanks anyway!
sfranky
 
Posts: 96
Joined: Mon Oct 19, 2009 10:06 pm


Return to General Discussion

Who is online

Users browsing this forum: Google [Bot] and 16 guests