- AuthorPosts
- February 17, 2008 at 3:20 pm #5460ttwiMember
“snippet” function in visual studio and many other IDEs saves a lot of time while programming, I really hope EmEditor would have a decent plugin which implements the same function.
March 6, 2008 at 2:32 pm #5551jonhutch24MemberI second that motion. This kind of functionality would make EmEditor nearly invaluable to me as a programmer.
April 23, 2008 at 2:01 pm #5687jonhutch24MemberOk what I would REALLY like is tab stops in the snippets. That’s my request! :)
April 23, 2008 at 4:05 pm #5688Yutaka EmuraKeymasterjonhutch24 wrote:
Ok what I would REALLY like is tab stops in the snippets. That’s my request! :)I am not sure what you want. You can use t as a tab character.
April 25, 2008 at 2:46 pm #5704jonhutch24MemberSorry, let me show you an example
Let’s say I make a snippet and it looks like this (this is just in theory):
if $con1$ = $con2$ then
$expression$
end ifNow when I run the snippet I’d like $con1$ already highlighted so I could just write over it, and when when I hit the tab key, it would move to $con2$ and highlight it so I could write over it, and when I hit tab again it would move to $expression$ and highlight it so I could type over it.
So my typing would look something like this:
Run the snippet
var1 -> TAB -> 23 -> TAB -> writeline(“It’s 23!”)and the text editor in the end would have:
if var1 = 23 then
writeline(“It’s 23!”)
end ifdoes this make any more sense? Sorry, I’m not very good at explaining things some times… :-?
April 25, 2008 at 3:59 pm #5705Yutaka EmuraKeymasterjonhutch24 wrote:
Sorry, let me show you an exampleLet’s say I make a snippet and it looks like this (this is just in theory):
if $con1$ = $con2$ then
$expression$
end ifNow when I run the snippet I’d like $con1$ already highlighted so I could just write over it, and when when I hit the tab key, it would move to $con2$ and highlight it so I could write over it, and when I hit tab again it would move to $expression$ and highlight it so I could type over it.
So my typing would look something like this:
Run the snippet
var1 -> TAB -> 23 -> TAB -> writeline(“It’s 23!”)and the text editor in the end would have:
if var1 = 23 then
writeline(“It’s 23!”)
end ifdoes this make any more sense? Sorry, I’m not very good at explaining things some times… :-?
Yes, that makes a perfect sense. Thanks!
April 25, 2008 at 8:13 pm #5709jonhutch24MemberAnother request for the snippets, is text expansion.
Take my last example for instance:
The snippet is:
if $con1$ = $con2$ then
$expression$
end ifIt would be nice if I could assign a command to type (in this example “ifstate”) and type something like:
ifstate -> TABAnd then have the snippet put the entire snippet in with $con1$ already highlighted. Not sure if this interferes with any of the other systems already in place, but it would be SUPER useful instead of having to go back and forth to the snippet pane. :D Thanks for the great product!
April 28, 2008 at 2:54 pm #5717jonhutch24MemberYAR! (Yet another Request)
Along with everything mentioned above, the ability to complete multiple tab stops by naming them the same and only typing over one.
Example (since I suck at explaining things):
I have the snippet:
while $var1$ = $answer$ continue
msgbox(“The user answered:” & $answer$)
end whileso when I fire it up (maybe by typing “mywhile” and hitting tab ;) ) I type something like this:
userAnswer -> TAB -> “Forty two” -> TABand the string “Forty two” is put in both places where $answer$ is so in the end it looks like:
while userAnswer = “Forty two” continue
msgbox(“The user answered:” & “Forty two” )
end whileDoes this make sense? I know I’m asking a lot from this snippet plug in. But it’s a VERY useful feature when doing a lot of repetitive coding… Thanks so much for your input and time!
:-DApril 28, 2008 at 3:02 pm #5718blackhawkParticipantI agree. So long as when you replace the first one, it does all the rest, then moves to the next tag.
Second me on this one!
April 28, 2008 at 3:43 pm #5719jonhutch24Memberblackhawk wrote:
I agree. So long as when you replace the first one, it does all the rest, then moves to the next tag.Good catch blackhawk! I knew I was forgetting something in that last example. :-? Yes, it would need to move on to the next unaltered tag when you hit tab. :-)
Edit: I just realized that this thread may not be the best place to do this. This thread (I believe) was started in regards to the autocomplete plugin. My requests are more snippet plug-in oriented. If you need us to move this to a new thread, I’ll be more than happy to copy and paste (or retype if necessary) everything others and myself have requested the snippet plugin do.
June 23, 2008 at 1:12 pm #5939jonhutch24MemberJust checking on the status of this and wondering if we’ll be seeing these features anytime soon?
June 23, 2008 at 10:52 pm #5943Yutaka EmuraKeymasterI will consider that in future. Thanks!
- AuthorPosts
- You must be logged in to reply to this topic.