StraightSegment class

A straight line segment from the current point to end.

This is the simplest segment type, creating a direct line. Used for:

  • Port extensions (the straight part coming out of a port)
  • Horizontal and vertical routing segments
  • Diagonal connections
Inheritance

Constructors

StraightSegment({required Offset end, bool generateHitTestRects = true})
const

Properties

end Offset
The endpoint of this segment.
finalinherited
generateHitTestRects bool
Whether to generate hit test rectangles for this segment.
finalinherited
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

getHitTestRects(Offset start, double tolerance) List<Rect>
Generates hit test rectangles for this segment.
override
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.
inherited