jump

Asked by kdurant

I define a snipet

snippet if
if(${1:/*condition*/})
{
 ${2:/*code*/}
}

and use it

if<tab>

it displayed

if(/*condition*/)
{
    /*code*/
}

The next operation are :<Esc>Gi
now ,it is insert mode, and enter:
kd<tab>

it jumped the line whre is the " /*code*/ "

but I want normal table here

Question information

Language:
English Edit question
Status:
Answered
For:
UltiSnips Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
SirVer (sirver) said :
#1

I do not understand what you mean with kd<tab>

what snippet should that expand?

If no snippet is defined with this trigger, everything is working as intended I think - you never leave the snippet with your move commands, so a tab will jump you forward because you were not yet at the last tabstop.

I think what you really want to do is not overloading the tab key - remap jump forward to another key. The engine can not know in your case what you really want from it.

Can you help with this problem?

Provide an answer of your own, or ask kdurant for more information if necessary.

To post a message you must log in.