This commit is contained in:
2024-09-07 09:34:54 +02:00
parent 4099fd4b91
commit 9ce0556bc9
8 changed files with 936 additions and 94 deletions

View File

@@ -297,13 +297,12 @@ class InkscapeUprint(inkex.Effect):
headings = [cell.value for cell in ws[1]]
substs = []
for row in ws.iter_rows(min_row=2, values_only=True):
substs.append(dict(zip(headings, row)))
if all([cell is None or cell.strip() == '' for cell in row]): continue
substs.append(dict(zip(headings, [cell if cell is not None else '' for cell in row])))
new_objects = []
for i, subst in enumerate(substs):
dup = self.duplicate_object(parent, selected)
# self.translate_object(dup, (i+1) * (self.x_offset + self.bbox.width), self.y_offset)
self.replace_text(dup, subst)
new_objects.append(dup)