neoscore.core.spanner_2d

class neoscore.core.spanner_2d.Spanner2D[source]

Bases: Spanner

A 2-dimensional Spanner.

__init__(end_pos: PointDef, end_parent: PositionedObject)[source]
Parameters
  • end_pos – The end point.

  • end_parent – The parent for the ending position.

property end_y: Unit

The y position of the endpoint as specified.

property end_pos: Point

The position of the endpoint

spanner_2d_length

The 2d length of the spanner.

This takes into account both the x and y-axis. For only the horizontal length, use Spanner.spanner_x_length.

angle

The angle from the start to end point in degrees.

The angle goes from the positive X axis to the end point. Positive angles go clockwise.