ClipboardCommands class abstract final

Clipboard operations: copy, cut, and paste.

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

copyCommand() Command
A Command that copies the selected text to the clipboard.
cutCommand() Command
A Command that cuts the selected text to the clipboard, removing it from the document.
cutSpec(EditorState state) TransactionSpec?
Returns a TransactionSpec that deletes the main selection and moves the cursor to the start of the deleted range. Returns null when the selection is empty (cursor only).
getSelectedText(EditorState state) String
Returns the text covered by the main selection, or an empty string when the selection is a cursor (empty range).
pasteCommand() Command
A Command that pastes plain text from the clipboard at the current selection, replacing any selected text.
pasteSpec(EditorState state, String text) TransactionSpec
Returns a TransactionSpec that inserts text at the current selection, replacing it when non-empty, and places the cursor after the inserted text.