On 6/9/22 7:56 PM, Ernie Rael wrote:
On 6/9/22 6:52 AM, Laszlo Kishalmi wrote:
You might also check how the editor handles the reload, and try to
improve the caret persistence situation.
Took another look this morning. Currently looks something like this
1. In DocumentOpenClose preReloadInEDT() is captures the carets from
all the open editor panes into reloadCaretOffsets.
2. After the reload, in AtomicLockedRun() thread, it creates java
Positions in new document using the saved caret offsets.
3. Then in EDT set the caret in any editors that hold that document
with the saved Positions.
The offset of caret is preserved from old to new doc. I'd guess that's
not what's wanted. But what are the desired semantics?
IMO, at step 1, create PositionRef of the caret offset, eliminate step
2, step 3 restore from the saved positionRefs.
Questions/issues
1. Would this change in behavior be OK?
2. Don't think there's any locking issues
3. Hasn't multiple carets/editor been introduced? What has to happen
around this?
-ernie
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@netbeans.apache.org
For additional commands, e-mail: dev-h...@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists