do you know a way to make something similar to thi...
# compose-desktop
z
do you know a way to make something similar to this in compose desktop. when i type in a text field i want a popup where the cursor is, but only if i type certain character combinations. i can do the content fine. i just need to popup UI at the correct position. also that the popup does not go off the screen.
a
I’m not at the computer right now, but Popup takes a position provider, and you can probably get the caret position from onTextLayout
z
are there some examples anywhere?
TextField() does not have onTextLayout :-(
a
BasicTextField
does
You can get the caret offset from
TextFieldValue
and use that to find its visual position from
TextLayoutResult
.