Does anyone have an idea on how to add context men...
# compose-desktop
s
Does anyone have an idea on how to add context menus to part of an
AnnotatedString
? When a link is clicked, I want to open the associated context menu. Currently, I'm using a
DropdownMenu
that opens in an arbitrary location, which isn't great.
a
Take a look at
LocalContextMenuData
s
Thanks. Is there any documentation on how this works?
a
Doesn’t seem to be. Maybe you can fimd something useful here: https://github.com/JetBrains/compose-multiplatform/issues/3493
I’m afk right now, and unfortunately don’t remember how to use it by heart.
Hmm, I may be barking up the wrong tree, having re-read your question.
You can probably get the position of your link from the text layout.
1