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

TextPresenter hides caret when there is non empty selection #16388

Open
filipkunc opened this issue Jul 21, 2024 · 1 comment
Open

TextPresenter hides caret when there is non empty selection #16388

filipkunc opened this issue Jul 21, 2024 · 1 comment

Comments

@filipkunc
Copy link

Is your feature request related to a problem? Please describe.

I have noticed that in TextPresenter has following logic on line 414:

if ((selectionStart != selectionEnd || !_caretBlink))
{
    return;
}

If I simply change it to:

if (!_caretBlink)
{
    return;
}

I see the caret also when there is a selection which helps me to understand if I am positioned at the start or at the end of the selection.

Describe the solution you'd like

I would like to have additional property on the TextBoxes and TextPresenter which would allow me to render the caret even when selection is empty.
I also think this issue #12809 should also be fixed because it would be more noticeable when this is added.

Describe alternatives you've considered

I know the default TextBox in WPF behaves the same, but consider using something like Excel which also uses under the hood a custom text editing control for in-cell editing. There it also keeps the caret for richer behavior. Same goes for most "code" editing controls.

Additional context

No response

@maxkatz6
Copy link
Member

See #16132 and #15770. There was a relevant discussion about mobile support. Desktop might need different defaults as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants