Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sync CaretIndex directly #16981

Merged
merged 1 commit into from
Sep 12, 2024
Merged

Conversation

Gillibald
Copy link
Contributor

@Gillibald Gillibald commented Sep 10, 2024

What does the pull request do?

It makes sure the CaretIndex is directly synced with the TextPresenter when the TextBox's value changes. This ensures the caret is always representing the current value.

What is the current behavior?

When the CaretIndex of the TextBox is changed in an OnPropertyChanged handler the changed value isn't synced with the TextPresenter.

What is the updated/expected behavior with this PR?

The caret is always at the correct position

How was the solution implemented (if it's not obvious)?

Checklist

Breaking changes

Obsoletions / Deprecations

Fixed issues

@avaloniaui-bot
Copy link

You can test this PR using the following package version. 11.2.999-cibuild0051736-alpha. (feed url: https://nuget-feed-all.avaloniaui.net/v3/index.json) [PRBUILDID]

@Gillibald Gillibald changed the title [WIP] Sync CaretIndex directly Sync CaretIndex directly Sep 11, 2024
@maxkatz6 maxkatz6 added the bug label Sep 12, 2024
@maxkatz6 maxkatz6 merged commit 533218d into AvaloniaUI:master Sep 12, 2024
11 checks passed
@Gillibald Gillibald added the backport-candidate-11.1.x Consider this PR for backporting to 11.1 branch label Sep 16, 2024
@Gillibald Gillibald deleted the fixes/caretIndexSync branch September 16, 2024 05:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-candidate-11.1.x Consider this PR for backporting to 11.1 branch bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants