Menu

#15 Nesting snippets with multiple fields

open
nobody
5
2009-10-14
2009-10-14
Anonymous
No

Scenario Description
Whet you have one snippet with more than one field and you try to use an other snippet while editing the first field you have to navigate to the next field of the first snippet manually, The replace key (tab) does not work any more because it will cycle you through the last used snippet.

Example
Snippet
if ($) {
$
} else {
$
}
Code to be written
if (false) {
if (false) {
//some code
} else {
//some code
}
} else {
//some code
}
The problem
if (//you type "false" here and hit the TAB to move on) {
//Here is where you come after the first TAB you type the snippet tag "if" and hit TAB
if (//you type "false" here and hit the TAB to move on) {
//you type come code here and hit the TAB to move on
} else {
//you type come code here BUT if you hit the TAB key you will move back to the if structure condition while you should go to the next
// block of code (else code) of the first snippet.
}
} else {
//you have to navigate here with the arrow keys (or mouse) because the TAB key does not work any more. :-(
}

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.