Skip to content

Commit 7418146

Browse files
committed
main
1 parent 2fef84a commit 7418146

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

dxf.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ def __init__(self, plan_name: str = "Survey Plan", scale: float = 1.0, dxf_versi
3232
self.doc.header["$AUNITS"] = 1 # Degrees/minutes/seconds
3333
self.doc.header["$AUPREC"] = 3 # 0d00'00"
3434
self.doc.header["$ANGBASE"] = 90.0 # set 0° direction to North
35-
print(dxf_version)
35+
self.dxf_version = dxf_version
36+
# print(dxf_version)
3637

3738
def setup_layers(self):
3839
self.doc.layers.add(name="LABELS", color=colors.BLACK)
@@ -751,7 +752,7 @@ def save_pdf(self, filepath: str = None, paper_size: str = "A4", orientation: st
751752
def save_dwg(self, dxf_filepath: str, filepath: str = None):
752753
if not filepath:
753754
filepath = f"{self.get_filename()}.dwg"
754-
odafc.convert(dxf_filepath, filepath)
755+
odafc.convert(dxf_filepath, filepath, version=self.dxf_version)
755756

756757
# def save(self, paper_size: str = "A4", orientation: str = "portrait"):
757758
# # with tempfile.TemporaryDirectory() as tmpdir:

0 commit comments

Comments
 (0)