There have been a number of snippets that I have wanted to create using $selected$ but I didn't want the snippet text appearing in place of the selection.
It would be helpful if there were a way to specify that the snippet text appear above/below the line containing the selection.
Something like the following would be great: $line up/down (or before/after)$<my snipet text>
I like this idea, because it would extend the possibilities. However using the prev. / next line can cause problems if you are in a multi-line expression (for examle a complex if) depending on what do you want to use it for. Can you give me some example idea?
I have had occassion to do this mostly when I wanted a snippet that operated on a class/method/variable name. I want to select the text of interest and then have a snippet generate the desired code from the selection.
For my purposes, your concern about multi-line expressions, method calls, etc., isn't that big an issue for me. I can always move the text generated by the snippet.
My goal here is to keep the snippet text from destroying/replacing the selected text.