fix: select buffer home/end behaviour when textarea's content overflows #522
+219
−5
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.
fixes #521 and makes possible to properly implement #518
overview from clod:
Problem: Shift+cmd+arrow keys (select to buffer home/end) didn't work correctly in scrollable Textareas because selection anchor coordinates were captured relative to the wrong viewport position.
Root Cause: updateSelectionForMovement stored selection anchor using viewport-relative visual coordinates. When the viewport scrolled during a large cursor jump, the anchor became invalid.
Solution:
fix tested in alacritty & kitty terminals
preview
https://github.com/user-attachments/assets/7a61e7f2-6a87-4cbf-843f-b760d9619f76