Fixes recently identified glitches, eliminates some code duplication, removes inessential STREAMHINT back references #1702
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This replaces PR #1673, which should be closed and deleted when this is merged.
BOUT (printing) should work better (but see issues in #1701), Move should be properly undoable (and undo-undoable), offscreen scrolling on the left should not garble the display.
The STREAMHINT xpointer field is still present but now only for its essential uses in line formatting and display. Those still need to be examined.
Remnants of an old strategy for screen updating were removed, hopefully will make it easier to fix lingering bugs.
Note that typing at the bottom of the screen still scrolls to the top rather than going up just a big to reveal the new caret line--next time.
With respect to undoing Move, undoing where the source and target are in the same document puts that document back to its previous state.
But if the source was taken from, and deleted in, a different Tedit document, undo doesn't undo the source deletion. If that document had been changed after the move, the deleted material would be inserted at some arbitrary place.
(It would be easy to detect whether the source document is in its original state so that the deletion could be sensibly undone. But that would require back-pointers between separate documents, causing either a circularity (using pointers) or the possibility of smashing a previously collected and perhaps reallocated structure (with xpointers).)