6

Is there any way to prevent cut, copy, paste in TextField in Android Jetpack Compose? I tried Modifier's pointerInput but it is not working.

Modifier.pointerInput(Unit) {
            detectTapGestures(onLongPress = {
                Toast.makeText(context, "long pressed", Toast.LENGTH_SHORT).show()
            })
        }

Is there any way to achieve this in Compose?

Ali_Waris
  • 1,944
  • 2
  • 28
  • 46
  • Does this answer your question? [Floating toolbar for text selection Jetpack Compose](https://stackoverflow.com/questions/68956792/floating-toolbar-for-text-selection-jetpack-compose) – Phil Dukhov Dec 22 '21 at 11:46
  • 1
    Does this answer your question? [How to disable copy/paste/cut in a TextField Jetpack Compose?](https://stackoverflow.com/questions/70518908/how-to-disable-copy-paste-cut-in-a-textfield-jetpack-compose) – Mahmudul Hasan Shohag Sep 06 '22 at 01:46

0 Answers0