diff --git a/Lib/fontParts/base/component.py b/Lib/fontParts/base/component.py index 0e5f791b..f054e2ed 100644 --- a/Lib/fontParts/base/component.py +++ b/Lib/fontParts/base/component.py @@ -49,6 +49,7 @@ class BaseComponent( inserted as part of an outline. """ + copyAttributes: Tuple[str, str] = ("baseGlyph", "transformation") def _reprContents(self) -> List[str]: @@ -227,7 +228,7 @@ def _set_baseGlyph(self, value: str) -> None: :return: A :ref:`type-transformation` value representing the transformation matrix of the component. - """ + """, ) def _get_base_transformation(self) -> SextupleType[float]: @@ -288,7 +289,7 @@ def _set_transformation(self, value: SextupleCollectionType[IntFloatType]) -> No :return: A :ref:`type-coordinate.` representing the offset of the component. - """ + """, ) def _get_base_offset(self) -> PairType[IntFloatType]: @@ -348,7 +349,7 @@ def _set_offset(self, value: PairCollectionType[IntFloatType]) -> None: :return: A :class:`tuple` of two :class:`float` items representing the ``(x, y)`` scale of the component. - """ + """, ) def _get_base_scale(self) -> PairType[float]: @@ -416,7 +417,7 @@ def _set_scale(self, value: PairCollectionType[IntFloatType]) -> None: :raise FontPartsError: If attempting to set the index while the component does not belong to a glyph. - """ + """, ) def _get_base_index(self) -> Optional[int]: @@ -740,18 +741,18 @@ def _get_base_bounds(self) -> QuadrupleType[float]: def _get_bounds(self) -> QuadrupleType[float]: """Get the bounds of the component. - This is the environment implementation of the :attr:`BaseComponent.bounds` - property getter. + This is the environment implementation of the :attr:`BaseComponent.bounds` + property getter. - :return: A :class:`tuple` of four :class:`int` or :class:`float` values - in the form ``(x minimum, y minimum, x maximum, y maximum)`` - representing the bounds of the component, or :obj:`None` if the - component is empty. The value will be normalized - with :func:`normalizers.normalizeBoundingBox`. + :return: A :class:`tuple` of four :class:`int` or :class:`float` values + in the form ``(x minimum, y minimum, x maximum, y maximum)`` + representing the bounds of the component, or :obj:`None` if the + component is empty. The value will be normalized + with :func:`normalizers.normalizeBoundingBox`. - .. note:: + .. note:: - Subclasses may override this method. + Subclasses may override this method. """ pen = BoundsPen(self.layer) diff --git a/Lib/fontParts/base/font.py b/Lib/fontParts/base/font.py index 0899ef0a..75002d68 100644 --- a/Lib/fontParts/base/font.py +++ b/Lib/fontParts/base/font.py @@ -2058,7 +2058,9 @@ def _interpolate( compatibilityReporterClass = FontCompatibilityReporter - def isCompatible(self, other: BaseFont, cls=None) -> Tuple[bool, FontCompatibilityReporter]: + def isCompatible( + self, other: BaseFont, cls=None + ) -> Tuple[bool, FontCompatibilityReporter]: """Evaluate interpolation compatibility with another font. This method will return a :class:`bool` indicating if the font is diff --git a/Lib/fontParts/base/glyph.py b/Lib/fontParts/base/glyph.py index f5530694..dc6c9a81 100644 --- a/Lib/fontParts/base/glyph.py +++ b/Lib/fontParts/base/glyph.py @@ -2795,7 +2795,9 @@ def _checkPairs( reporter.warning = True reporterObject.append(compatibility) - def isCompatible(self, other: BaseGlyph, cls=None) -> Tuple[bool, GlyphCompatibilityReporter]: + def isCompatible( + self, other: BaseGlyph, cls=None + ) -> Tuple[bool, GlyphCompatibilityReporter]: """Evaluate interpolation compatibility with another glyph. :param other: The other :class:`BaseGlyph` instance to check diff --git a/Lib/fontParts/base/layer.py b/Lib/fontParts/base/layer.py index ad60e970..8c365a0f 100644 --- a/Lib/fontParts/base/layer.py +++ b/Lib/fontParts/base/layer.py @@ -1107,7 +1107,9 @@ def _interpolate( compatibilityReporterClass = LayerCompatibilityReporter - def isCompatible(self, other: BaseLayer, cls=None) -> Tuple[bool, LayerCompatibilityReporter]: + def isCompatible( + self, other: BaseLayer, cls=None + ) -> Tuple[bool, LayerCompatibilityReporter]: """Evaluate interpolation compatibility with another layer. :param other: The other :class:`BaseLayer` instance to check