fix in export as selection

This commit is contained in:
Mario Voigt 2021-04-19 22:33:56 +02:00
parent 440c883cce
commit 67c7cea393
1 changed files with 3 additions and 5 deletions

View File

@ -78,11 +78,9 @@ class ExportObject(inkex.EffectExtension):
elem_copy.attrib['transform'] = str(elem.composed_transform())
group.append(elem_copy)
width = math.ceil(bbox.width)
height = math.ceil(bbox.height)
template.attrib['viewBox'] = f'0 0 {width} {height}'
template.attrib['width'] = f'{width}' + self.svg.unit
template.attrib['height'] = f'{height}' + self.svg.unit
template.attrib['viewBox'] = f'0 0 {bbox.width} {bbox.height}'
template.attrib['width'] = f'{bbox.width}' + self.svg.unit
template.attrib['height'] = f'{bbox.height}' + self.svg.unit
if filename is None:
filename = elem.attrib.get('id', None)