BPoint¶
Must Override¶
May Override¶
- BaseBPoint._get_anchor() tuple[int | float, int | float][source]¶
Get the bPoint’s anchor point.
This is the environment implementation of the
BaseBPoint.anchorproperty getter.- Returns:
a Coordinate representing the anchor point of the bPoint. The value will be normalized with
normalizers.normalizeCoordinateTuple.
Note
Subclasses may override this method.
- BaseBPoint._get_bcpIn() tuple[int | float, int | float][source]¶
Get the bPoint’s incoming off-curve.
This is the environment implementation of the
BaseBPoint.bcpInproperty getter.- Returns:
A Coordinate representing the incoming off-curve of the bPoin. The value will be normalized with
normalizers.normalizeCoordinateTuple.
Note
Subclasses may override this method.
- BaseBPoint._get_bcpOut() tuple[int | float, int | float][source]¶
Get the bPoint’s outgoing off-curve.
This is the environment implementation of the
BaseBPoint.bcpOutproperty getter.- Returns:
A Coordinate representing the outgoing off-curve of the bPoin. The value will be normalized with
normalizers.normalizeCoordinateTuple.
Note
Subclasses may override this method.
- BaseBPoint._get_index() int | None[source]¶
Get the index of the native bPoint.
This is the environment implementation of the
BaseBPoint.indexproperty getter.- Returns:
An
intrepresenting the bPoint’s index within an ordered list of the parent contour’s bPoints, orNoneif the bPoint does not belong to a contour. The value will be normalized withnormalizers.normalizeIndex.
Note
Subclasses may override this method.
- BaseBPoint._get_type() str[source]¶
Get the bPoint’s type.
This is the environment implementation of the
BaseBPoint.typeproperty getter.- Returns:
A
strrepresenting the type of the bPoint. The value will be normalized withnormalizers.normalizeBPointType.- Raises:
FontPartsError – If the point’s type cannot be converted to a valid bPoint type.
Note
Subclasses may override this method.
- BaseBPoint._init(*args: Any, **kwargs: Any) None¶
Initialize the native object.
This is the environment implementation of
BaseObject.__init__.- Parameters:
*args – Any positional arguments.
**kwargs – Any keyword arguments.
Note
Subclasses may override this method.
- BaseBPoint._moveBy(value: list[int | float] | tuple[int | float, int | float], **kwargs: Any) None¶
Move the native object according to the given coordinates.
This is the environment implementation of
BaseObject.moveBy.- Parameters:
value – The x and y values to move the object by as a Coordinate. The value will have been normalized with
normalizers.normalizeTransformationOffset.**kwargs – Additional keyword arguments.
Note
Subclasses may override this method.
- BaseBPoint._rotateBy(value: float, origin: list[int | float] | tuple[int | float, int | float], **kwargs: Any) None¶
Rotate the native object by the specified value.
This is the environment implementation of
TransformationMixin.rotateBy.- Parameters:
value – The angle at which to rotate the object as an
intor afloat. The value will have been normalized withnormalizers.normalizeRotationAngle.origin – The point at which the rotation should originate as a Coordinate or
None. The value will have been normalized withnormalizers.normalizeCoordinateTuple.**kwargs – Additional keyword arguments.
Note
Subclasses may override this method.
- BaseBPoint._scaleBy(value: list[int | float] | tuple[float, float], origin: list[int | float] | tuple[int | float, int | float], **kwargs: Any) None¶
Scale the native object according to the given values.
This is the environment implementation of
BaseObject.scaleBy.- Parameters:
value – The value to scale the glyph by as a single
intorfloat, or atupleorlistof twointorfloatvalues representing the values(x, y). The value will have been normalized withnormalizeTransformationScale.origin – The point at which the scale should originate as a Coordinate or
None. The value will have been normalized withnormalizers.normalizeCoordinateTuple.**kwargs – Additional keyword arguments.
Note
Subclasses may override this method.
- BaseBPoint._set_anchor(value: list[int | float] | tuple[int | float, int | float]) None[source]¶
Set the bPoint’s anchor point.
This is the environment implementation of the
BaseBPoint.anchorproperty setter.- Parameters:
value – The anchor point to set as a Coordinate. The value will have been normalized with
normalizers.normalizeCoordinateTuple.
Note
Subclasses may override this method.
- BaseBPoint._set_bcpIn(value: list[int | float] | tuple[int | float, int | float]) None[source]¶
Set the bPoint’s incoming off-curve.
This is the environment implementation of the
BaseBPoint.bcpInproperty setter.- Parameters:
value – The incoming off-curve to set as a Coordinate. The value will have been normalized with
normalizers.normalizeCoordinateTuple.- Raises:
FontPartsError – When attempting to set the incoming off-curve for a the first point in an open contour.
Note
Subclasses may override this method.
- BaseBPoint._set_bcpOut(value: list[int | float] | tuple[int | float, int | float]) None[source]¶
Set the bPoint’s outgoing off-curve.
This is the environment implementation of the
BaseBPoint.bcpOutproperty setter.- Parameters:
value – The outgoing off-curve to set as a Coordinate. The value will have been normalized with
normalizers.normalizeCoordinateTuple.- Raises:
FontPartsError – When attempting to set the outgoing off-curve for a the last point in an open contour.
Note
Subclasses may override this method.
- BaseBPoint._set_type(value: str) None[source]¶
Set the bPoint’s type.
This is the environment implementation of the
BaseBPoint.typeproperty setter.- Parameters:
value – The outgoing off-curve to set as a
str. The value will have been normalized withnormalizers.normalizeBPointType.
Note
Subclasses may override this method.
- BaseBPoint._skewBy(value: list[int | float] | tuple[float, float], origin: list[int | float] | tuple[int | float, int | float], **kwargs: Any) None¶
Skew the native object by the given value.
This is the environment implementation of
TransformationMixin.skewBy.- Parameters:
value – The value by which to skew the object as either a single
intorfloatcorresponding to the x direction, or atupleof twointorfloatvalues corresponding to the x and y directions. The value will have been normalized withnormalizers.normalizeTransformationSkewAngle.origin – The point at which the rotation should originate as a Coordinate or
None. The value will have been normalized withnormalizers.normalizeCoordinateTuple.**kwargs – Additional keyword arguments.
Note
Subclasses may override this method.
- BaseBPoint._transformBy(matrix: list[int | float] | tuple[float, float, float, float, float, float], **kwargs: Any) None[source]¶
Transform the native bPoint.
This is the environment implementation of
BaseBPoint.transformBy.- Parameters:
matrix – The transformation to apply as a Transformation Matrix.
**kwargs – Additional keyword arguments.
Note
Subclasses may override this method.