Clipboard

Methods
4
Fields
None

Getting one

Toolkit.getDefaultToolkit():getSystemClipboard()

Methods

MethodReturnsDescription
setContents(StringSelection, nil)()Put contents's text on the clipboard. owner is never told it lost ownership.
getData(DataFlavor)stringThe clipboard's text for flavor (DataFlavor.stringFlavor); no text is UnsupportedFlavorException. Any plugin reads it at any time.
isDataFlavorAvailable(DataFlavor)booleanWhether the clipboard holds text.
getContents(any)StringSelection?The clipboard's text as a StringSelection, or nil when it holds none. Any plugin reads it at any time.

Returned by

MethodReturnsDescription
Toolkit.getSystemClipboardClipboardThe system clipboard.

Method details

getData

getData: (Clipboard, DataFlavor) -> string

The clipboard's text for flavor (DataFlavor.stringFlavor); no text is UnsupportedFlavorException. Any plugin reads it at any time.