Issue with text layer rendering: pdfjs v3.3.122 #18262
Unanswered
marija-popovic
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Since upgrading from pdfjs v2.5.207 to pdfjs v3.3.122 I have had issues with rendering a text layer of pdfs. Previously, for this purpose, class TextLayerBuilder was used and it was working correctly.
This is the code that was used:
Now, the constructor of TextLayerBuilder doesn't accept the same parameters as before and it is not clear how the same behavior should be achieved with these changes. Instead, I tried to use renderTextLayer function:
but it resulted in having issues with the alignment and font size of the pdf text, for example:
I would appreciate if some instructions for overcoming this issue could be provided, either with the usage of TextLayerBuilder or renderTextLayer.
Beta Was this translation helpful? Give feedback.
All reactions