Replies: 1 comment 4 replies
-
I don't think the |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am in the situation where the selection is set programmatically using the following:
(or similar, e.g.
setSelectionRanges
)However, this positions the caret (cursor) at the end of the selection but I want to position it differently.
I tried to use
sourceViewer.getTextWidget.setCaretOffset()
and similar but either the caret is position correctly (with nothing being selected - if I set the caret last) or the selection overwrites the caret.For context: The selection is modified and is restored to its previous state causing a bug in wildwebdeveloper/lsp4e I want to get fixed and contributing it is the best way to actually get it done.
Any other way of saving and restoring the selection including the caret would be a useful alternative as well.
Beta Was this translation helpful? Give feedback.
All reactions