How to customize a caret of TextBox in UWP?

水 知 165 Reputation points
2024-09-28T15:26:26.3066667+00:00

I want to make customized TextBox and I don't know how to customize the caret in UWP.

I thought of these ways to make it:

  1. Change the style of the original caret directly
  2. Use a rectangle and let it blink, but how to hide the original caret or how to make the new one blink at the same time as the orignal one?
  3. Remake a TextBox, but how to do it and make it support IME?

Please help!

Developer technologies Universal Windows Platform (UWP)
{count} votes

Accepted answer
  1. Junjie Zhu - MSFT 21,646 Reputation points
    2024-10-10T03:21:50+00:00

    Hello @水 知 ,

    To summarize this question. Currently, there is no public API in UWP that can achieve caret with rounded edges on the top and bottom, only simple modifications can be implemented in UWP.

    Thank you.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.