- Code: Select all
123456789
|23456789
|13456789
|12456789
|12356789
|12346789
The second line is a single space so "1" is removed, the third is two spaces so "2" is removed. The | is actually ending up where the cursor is supposed to be according to the snippet. So, if you change the 123456789 snippet to be "1234" in "before caret" and "56789" to "after caret" you get:
- Code: Select all
one tab: 1234|5679 with the caret blinking between 7 and 9
two spaces: 1234|5789 with the caret between 5 and 7
anything position beyond 10 columns: 1234|5678 with the caret after the 8
Your cursor ends up as equal to: whatever your starting position was + the position of the caret according to the snippet.
Couple of other scenarios I came across:
If the snippet only has content in the "before" box
or
If the snippet has a linebreak in the before or after boxes, it renders fine from any position but it is rendered starting at column 1. For instance, try it with the included javascript function() snippet.
I'm using 9.0.0.97.
Thanks,
Will