PieceSquareArgs class

What SquarePieceBuilder is asked to draw: one piece on one square.

Constructors

PieceSquareArgs({required SquareInfo square, required String piece, required double size, SquareInfo? from, Offset? fromOffset, bool animated = false, bool dragFeedback = false})
const

Properties

animated → bool
Whether the board animates this state change (the animation flag of WPChessboardController.setFen).
final
dragFeedback → bool
True when the board asks for what follows the finger while the piece is dragged. from is null then.
final
from → SquareInfo?
The square the piece came from in this state change, or null when it did not move (or the board could not tell where it came from).
final
fromOffset → Offset?
Where from lies, seen from square, in logical pixels in the piece's own upright frame: a widget translated by this offset stands on from. It already accounts for the board's orientation and for a top player's piece that is turned around. Null exactly when from is null.
final
hashCode → int
The hash code for this object.
no setterinherited
moved → bool
Whether the piece arrived on square in this state change, with the board animating it.
no setter
piece → String
The board letter of the piece, "P" for a white pawn, "n" for a black knight.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
size → double
The size of a square in logical pixels.
final
square → SquareInfo
The square the piece stands on.
final

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