Sprotty
Toggle Dark/Light/Auto modeToggle Dark/Light/Auto modeToggle Dark/Light/Auto modeBack to homepage

Class. Point to Point Line

b

Get Signature

get b(): number

Defined in: packages/sprotty/src/utils/geometry.ts:132

Returns

number

Implementation of

Line.b


c

Get Signature

get c(): number

Defined in: packages/sprotty/src/utils/geometry.ts:136

Returns

number

Implementation of

Line.c


direction

Get Signature

get direction(): CardinalDirection

Defined in: packages/sprotty/src/utils/geometry.ts:169

The direction of this line, such as ’north’, ‘south’, or ‘south-west’.

Returns

CardinalDirection


slope

Get Signature

get slope(): undefined | number

Defined in: packages/sprotty/src/utils/geometry.ts:151

The slope of the line. A vertical line returns undefined.

Returns

undefined | number


slopeOrMax

Get Signature

get slopeOrMax(): number

Defined in: packages/sprotty/src/utils/geometry.ts:159

The slope of the line or Number.MAX_SAFE_INTEGER if vertical.

Returns

number

Methods

hasIndistinctPoints()

hasIndistinctPoints(otherLine): boolean

Defined in: packages/sprotty/src/utils/geometry.ts:237

Parameters

otherLine

PointToPointLine

the other line

Returns

boolean

whether the start and end point of this line is does not have distinct start or end points with the otherLine


intersection()

intersection(otherLine): undefined | Point

Defined in: packages/sprotty/src/utils/geometry.ts:197

Parameters

otherLine

PointToPointLine

the other line

Returns

undefined | Point

the intersection point between this line and the otherLine if exists, or undefined.