KeyGeometry class final
One resolved key outline: a KeyShapeKind (plus the Material shape id for KeyShapeKind.m3eMorph) and its corner radius as a fraction of the short side (0–0.5).
- Annotations
Constructors
- KeyGeometry(KeyShapeKind kind, {M3eShape? m3eShape, int cornerPermille = 300})
-
const
- KeyGeometry.roundedRect(int cornerPermille)
-
A rounded rectangle with
cornerPermille/ 1000 of the short side.const
Properties
- cornerFraction → double
-
Corner radius as a fraction of the short side, clamped to 0–0.5.
no setter
- cornerPermille → int
-
Corner radius, fraction of the short side × 1000 (0–500).
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- isRectLike → bool
-
Whether this outline is a (rounded) rectangle family shape whose
corners scale exactly with the short side (circle, pill, squircle…).
no setter
- kind → KeyShapeKind
-
Outline kind.
final
- m3eShape → M3eShape?
-
Material shape id (KeyShapeKind.m3eMorph only).
final
- 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.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Constants
- fullRound → const KeyGeometry
- A full-round key: a circle in a square cell, a stadium otherwise.