I’m trying my hand at developing a package. My functionality requires a new text editor for an already-open file. How can I achieve this?
Initially, I hoped I could do something like this:
- Get a handle
editorto the current
editorto get a handle
- Create a new
However, I can’t find the methods to do this. I expected
TextBuffer to have an
addTextEditor() method, or
TextEditor to have a
setBuffer() method, or something along those lines.
I figure I can probably get a new
TextEditor into my file if I’m willing to do it in a separate pane (using the URI method of opening a file); however, I’d much prefer to keep it in the same pane if possible.