Reputation: 2970
I want to decrease the 'height' of cursor in my TextField. How do I do that?
My TextField with default cursor height looks like:
Upvotes: 2
Views: 3686
Reputation: 651
We can custom the text field cursor via CoreTextField.cursorBrush
, with Brush.verticalGradient
and colorStops
argument.
BasicTextField(
cursorBrush = Brush.verticalGradient(
0.00f to Color.Transparent,
0.35f to Color.Transparent,
0.35f to Color.Green,
0.90f to Color.Green,
0.90f to Color.Transparent,
1.00f to Color.Transparent
)
)
Upvotes: 1