Skip to content

Conversation

@mgarstenauer
Copy link
Contributor

An AvaloniaEdit user has discovered a problem with rectangular selection when virtual space is enabled. See AvaloniaUI/AvaloniaEdit#472.

I provided a fix for AvaloniaEdit: AvaloniaUI/AvaloniaEdit#496

AvalonEdit shows the same problem. This PR implements the fix for AvalonEdit.

Details:
When a selection extends beyond the visual line into the "virtual space" then the BackgroundGeometryBuilder creates two segments per line. One for the visible text, and one for the virtual space.

The segment for the virtual space didn't apply the scroll offset. This is now fixed.

@siegfriedpammer siegfriedpammer merged commit 326acc0 into icsharpcode:master Apr 12, 2025
0 of 4 checks passed
@siegfriedpammer
Copy link
Member

Thank you for your contribution!

@mgarstenauer mgarstenauer deleted the fix-rect-selection-ignores-scrolloffset branch April 12, 2025 19:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants