move to dicty layers and targets

This commit is contained in:
jan 2023-04-12 13:56:50 -07:00
commit 9a077ea2df
23 changed files with 694 additions and 638 deletions

View file

@ -1,4 +1,4 @@
from typing import Self, Sequence, Mapping, Literal, overload, Final, cast
from typing import Self, Sequence, Mapping, Literal, overload
import copy
import logging
@ -482,10 +482,10 @@ class Builder(PortList):
self.pattern.append(other_copy)
else:
assert not isinstance(other, Pattern)
ref = Ref(other.name, mirrored=mirrored)
ref = Ref(mirrored=mirrored)
ref.rotate_around(pivot, rotation)
ref.translate(offset)
self.pattern.refs.append(ref)
self.pattern.refs[other.name].append(ref)
return self
def translate(self, offset: ArrayLike) -> Self: