PCanvasKeyEvent class

A PCanvas key event. See PCanvas.onKey.

Inheritance

Constructors

PCanvasKeyEvent(String type, int charCode, String? code, String? key, bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, {PCanvasKeyEvent? parentEvent, PCanvasElement? targetElement, PCanvas? pCanvas, Object? nativeEvent})
const

Properties

altKey bool
Whether the "ALT" key was pressed.
final
charCode int
The Unicode value of the key:
final
code String?
The code of the key (the name of the key).
final
ctrlKey bool
Whether the "CTRL" key was pressed.
final
hashCode int
The hash code for this object.
no setteroverride
key String?
The key value.
final
metaKey bool
Whether the "META" key was pressed.
final
nativeEvent Object?
The native event object.
finalinherited
parentElement PCanvasElement?
The parent PCanvasElement of this event. See parentEvent.
no setterinherited
parentEvent PCanvasKeyEvent?
The event received by the parent element.
no setteroverride
pCanvas PCanvas?
The PCanvas processing this event.
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
shiftKey bool
Whether the "SHIFT" key was pressed.
final
targetElement PCanvasElement?
The target PCanvasElement of this event.
finalinherited
type String
The event type.
finalinherited

Methods

copyWith({String? type, int? charCode, String? code, String? key, bool? ctrlKey, bool? altKey, bool? shiftKey, bool? metaKey, PCanvasElement? targetElement, PCanvasKeyEvent? parentEvent, PCanvas? pCanvas}) PCanvasKeyEvent
Copies this instance overwriting with the passed parameters.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
preventDefault([PCanvas? pCanvas]) bool
Prevents PCanvasEvent.nativeEvent default behavior if pCanvas parameter or field is provided.
inherited
toInfoString({bool withParentEvents = true, bool withType = true, String indent = ''}) String
override
toString({bool withParentEvents = true}) String
A string representation of this object.
override

Operators

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