Skip to content

Commit 6d42585

Browse files
committed
Fixed wrong height calculation
1 parent 469c671 commit 6d42585

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

barcode/writer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ def calculate_size(self, modules_per_line: int, number_of_lines: int) -> tuple:
155155
number_of_text_lines = len(self.text.splitlines())
156156
if self.font_size and self.text:
157157
height += (
158-
pt2mm(self.font_size) / 2 * number_of_text_lines + self.text_distance
158+
pt2mm(self.font_size) * number_of_text_lines + self.text_distance
159159
)
160160
height += self.text_line_distance * (number_of_text_lines - 1)
161161
return width, height

0 commit comments

Comments
 (0)