public native copyToClipboard(text as String) as Boolean
Copies plain text to the operating-system clipboard.
The visible native window owns the clipboard selection on platforms such as X11. The method therefore belongs to Window rather than to a global utility object.
| Parameter | Description |
|---|---|
text | Plain text to copy. |
True when the native backend accepted the clipboard contents.
if window.copyToClipboard("Build completed"):
print("Copied")