Function

copy

The method for copying text.

copy

Source set: Common
suspend fun copy(cancelSelection: Boolean = true)

The method for copying text.

If there is no selection, return. Put the selected text into the Clipboard, and cancel the selection, if cancelSelection is true. The text in the text field should be unchanged. If cancelSelection is true, the new cursor offset should be at the end of the previous selected text.

Jetpack Compose beyond MaterialFree components, screens and templates for apps that don’t look like Google’s. Copy them into your app, or let your coding agent add them.Browse for free

Content updated: