From 9b58fc19723a45a97cc71017e7b616aee63d5b86 Mon Sep 17 00:00:00 2001 From: etern4l-white Date: Thu, 1 Feb 2024 05:28:54 -0500 Subject: [PATCH 1/2] Updated extract-text.md in docs --- docs/user/extract-text.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/user/extract-text.md b/docs/user/extract-text.md index 573824d2b..7a269820b 100644 --- a/docs/user/extract-text.md +++ b/docs/user/extract-text.md @@ -84,7 +84,7 @@ parts = [] def visitor_body(text, cm, tm, font_dict, font_size): - y = cm[5] + y = tm[5] if y > 50 and y < 720: parts.append(text) @@ -119,7 +119,7 @@ def visitor_svg_rect(op, args, cm, tm): def visitor_svg_text(text, cm, tm, fontDict, fontSize): - (x, y) = (cm[4], cm[5]) + (x, y) = (tm[4], tm[5]) dwg.add(dwg.text(text, insert=(x, y), fill="blue")) From bcf5d33be4d01ba95eae698d81d88a88831ffed8 Mon Sep 17 00:00:00 2001 From: eternal white <157317414+etern4l-white@users.noreply.github.com> Date: Thu, 1 Feb 2024 06:22:51 -0500 Subject: [PATCH 2/2] Update docs/user/extract-text.md Added by @stefan6419846 Co-authored-by: Stefan <96178532+stefan6419846@users.noreply.github.com> --- docs/user/extract-text.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/user/extract-text.md b/docs/user/extract-text.md index 7a269820b..3eb2788cb 100644 --- a/docs/user/extract-text.md +++ b/docs/user/extract-text.md @@ -118,7 +118,7 @@ def visitor_svg_rect(op, args, cm, tm): dwg.add(dwg.rect((x, y), (w, h), stroke="red", fill_opacity=0.05)) -def visitor_svg_text(text, cm, tm, fontDict, fontSize): +def visitor_svg_text(text, cm, tm, font_dict, font_size): (x, y) = (tm[4], tm[5]) dwg.add(dwg.text(text, insert=(x, y), fill="blue"))