Clipboard


Summary

Public functions

suspend ClipEntry?

Returns the clipboard entry that's provided by the platform's ClipboardManager.

Cmn
suspend Unit
setClipEntry(clipEntry: ClipEntry?)

Puts the given clipEntry in platform's ClipboardManager.

Cmn

Public properties

NativeClipboard

Returns the native clipboard that exposes the full functionality of platform clipboard.

Cmn

Public functions

getClipEntry

suspend fun getClipEntry(): ClipEntry?

Returns the clipboard entry that's provided by the platform's ClipboardManager.

This item can include arbitrary content like text, images, videos, or any data that may be provided through a mediator. Returned entry may contain multiple items with different types.

It returns null when the clipboard is empty.

Calling this function on Android will access the Clipboard's contents, and the first time it happens this will trigger a warning that says "App pasted from Clipboard". Use nativeClipboard and primaryClipDescription on Android to circumvent this issue if you are only interested in querying what is available in the clipboard.

setClipEntry

suspend fun setClipEntry(clipEntry: ClipEntry?): Unit

Puts the given clipEntry in platform's ClipboardManager.

Parameters
clipEntry: ClipEntry?

Platform specific clip object that either holds data or links to it. Pass null to clear the clipboard.

Public properties

nativeClipboard

val nativeClipboardNativeClipboard

Returns the native clipboard that exposes the full functionality of platform clipboard.