Skip to main content

hLine()

Draws a horizontal line of the given distance. Chain .centered() to center the line on the current position.

Returns: HLine

Signatures

hLine(distance: number): HLine

Draws a horizontal line of the given distance. Chain .centered() to center the line on the current position.

ParameterTypeDescription
distancenumberThe line length

hLine(target: SceneObject): HLine

Draws a horizontal line that ends where it intersects the target geometry. The nearest intersection (in either direction along the X axis) is used.

ParameterTypeDescription
targetSceneObjectThe geometry to intersect with

hLine(start: Point2DLike, distance: number): HLine

Draws a horizontal line from a start point. Chain .centered() to center the line on the start point.

ParameterTypeDescription
startPoint2DLikeThe start point
distancenumberThe line length

hLine(start: Point2DLike, target: SceneObject): HLine

Draws a horizontal line from a start point that ends where it intersects the target geometry. The nearest intersection (in either direction along the X axis) is used.

ParameterTypeDescription
startPoint2DLikeThe start point
targetSceneObjectThe geometry to intersect with

hLine(targetPlane: SceneObject | PlaneLike, distance: number): HLine

Draws a horizontal line on a specific plane.

ParameterTypeDescription
targetPlaneSceneObject | PlaneLikeThe plane to draw on
distancenumberThe line length