Fix dashes

This commit is contained in:
James R. Barlow
2023-11-19 23:51:26 -08:00
parent 60645717e2
commit b73af7ce10
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -341,7 +341,7 @@ class HocrTransform:
if show_bounding_boxes: # pragma: no cover
# draw the baseline in magenta, dashed
pdf.set_dash()
pdf.set_dashes()
pdf.set_stroke_color(magenta)
pdf.set_line_width(0.5)
# negate slope because it is defined as a rise/run in pixel
@@ -353,7 +353,7 @@ class HocrTransform:
self.polyval((-slope, baseline_y2), line_box.x2 - line_box.x1),
)
# light green for bounding box of word/line
pdf.set_dash(6, 3)
pdf.set_dashes(6, 3)
pdf.set_stroke_color(red)
text.set_text_transform(cos_a, -sin_a, sin_a, cos_a, line_box.x1, baseline_y2)
+1 -1
View File
@@ -42,7 +42,7 @@ class Canvas(ABC):
pass
@abstractmethod
def set_dashes(self, dashes):
def set_dashes(self, array, phase):
pass
@abstractmethod