NmGalaxyPoint class
Position of a property in the galaxy visualization Coordinates are normalized 0.0-1.0 for dimension-independent layout
Constructors
- NmGalaxyPoint({required String propertyId, required double x, required double y, double radius = 16.0, Color color = Colors.blue, double opacity = 1.0})
-
Creates a NmGalaxyPoint.
const
Properties
- color → Color
-
Color.
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- opacity → double
-
Opacity.
final
- propertyId → String
-
Property id.
final
- radius → double
-
Radius.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- x → double
-
X.
final
- y → double
-
Y.
final
Methods
-
containsPoint(
Offset point, Size canvasSize) → bool - Check if a point (in normalized coordinates) is within this position's radius
-
copyWith(
{String? propertyId, double? x, double? y, double? radius, Color? color, double? opacity}) → NmGalaxyPoint - Copy with.
-
distanceTo(
NmGalaxyPoint other) → double - Distance to another position in normalized space
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toOffset(
Size canvasSize) → Offset - Convert normalized coordinates to canvas offset
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Static Methods
-
fromOffset(
Offset offset, Size canvasSize, String propertyId, {double radius = 16.0, Color color = Colors.blue}) → NmGalaxyPoint - Create from canvas offset (inverse of toOffset)
-
lerp(
NmGalaxyPoint a, NmGalaxyPoint b, double t) → NmGalaxyPoint - Interpolate between two positions for animation