misc cleanup
This commit is contained in:
parent
ef6c5df386
commit
da7118f521
@ -332,9 +332,9 @@ class Arbitrary(Repetition):
|
|||||||
|
|
||||||
@displacements.setter
|
@displacements.setter
|
||||||
def displacements(self, val: ArrayLike) -> None:
|
def displacements(self, val: ArrayLike) -> None:
|
||||||
vala: NDArray[numpy.float64] = numpy.array(val, dtype=float)
|
vala = numpy.array(val, dtype=float)
|
||||||
vala = numpy.sort(vala.view([('', vala.dtype)] * vala.shape[1]), 0).view(vala.dtype) # sort rows
|
order = numpy.lexsort(vala.T[::-1]) # sortrows
|
||||||
self._displacements = vala
|
self._displacements = vala[order]
|
||||||
|
|
||||||
def __init__(
|
def __init__(
|
||||||
self,
|
self,
|
||||||
|
@ -230,7 +230,8 @@ def get_char_as_polygons(
|
|||||||
outline = slot.outline
|
outline = slot.outline
|
||||||
|
|
||||||
start = 0
|
start = 0
|
||||||
all_verts_list, all_codes = [], []
|
all_verts_list = []
|
||||||
|
all_codes = []
|
||||||
for end in outline.contours:
|
for end in outline.contours:
|
||||||
points = outline.points[start:end + 1]
|
points = outline.points[start:end + 1]
|
||||||
points.append(points[0])
|
points.append(points[0])
|
||||||
|
Loading…
Reference in New Issue
Block a user