misc doc/import/typing fixes

This commit is contained in:
Jan Petykiewicz 2020-09-18 19:47:31 -07:00
parent 3f59168cec
commit f51144ae6a
4 changed files with 7 additions and 4 deletions

View File

@ -5,7 +5,7 @@ from numpy import pi
from .repetition import Repetition from .repetition import Repetition
from .error import PatternError, PatternLockedError from .error import PatternError, PatternLockedError
from .utils import is_scalar, vector2, rotation_matrix_2d, layer_t, AutoSlots, annotations_t from .utils import vector2, rotation_matrix_2d, layer_t, AutoSlots, annotations_t
from .traits import PositionableImpl, LayerableImpl, Copyable, Pivotable, LockableImpl, RepeatableImpl from .traits import PositionableImpl, LayerableImpl, Copyable, Pivotable, LockableImpl, RepeatableImpl
from .traits import AnnotatableImpl from .traits import AnnotatableImpl

View File

@ -916,8 +916,8 @@ class Pattern(LockableImpl, AnnotatableImpl, metaclass=AutoSlots):
overdraw: Whether to create a new figure or draw on a pre-existing one overdraw: Whether to create a new figure or draw on a pre-existing one
""" """
# TODO: add text labels to visualize() # TODO: add text labels to visualize()
from matplotlib import pyplot from matplotlib import pyplot # type: ignore
import matplotlib.collections import matplotlib.collections # type: ignore
offset = numpy.array(offset, dtype=float) offset = numpy.array(offset, dtype=float)

View File

@ -5,7 +5,7 @@ import copy
import numpy # type: ignore import numpy # type: ignore
from ..error import PatternError, PatternLockedError from ..error import PatternError, PatternLockedError
from ..utils import is_scalar, rotation_matrix_2d, vector2, layer_t from ..utils import rotation_matrix_2d, vector2, layer_t
from ..traits import (PositionableImpl, LayerableImpl, DoseableImpl, from ..traits import (PositionableImpl, LayerableImpl, DoseableImpl,
Rotatable, Mirrorable, Copyable, Scalable, Rotatable, Mirrorable, Copyable, Scalable,
PivotableImpl, LockableImpl, RepeatableImpl, PivotableImpl, LockableImpl, RepeatableImpl,

View File

@ -1,3 +1,6 @@
"""
Traits (mixins) and default implementations
"""
from .positionable import Positionable, PositionableImpl from .positionable import Positionable, PositionableImpl
from .layerable import Layerable, LayerableImpl from .layerable import Layerable, LayerableImpl
from .doseable import Doseable, DoseableImpl from .doseable import Doseable, DoseableImpl