Polish letters in form fields cause text misalignment #4808
Replies: 2 comments 1 reply
-
| Please consult the documentation: |
Beta Was this translation helpful? Give feedback.
-
| Actually, there does exist a circumvention which I am planning to make part of the official package at some time.
After this, the text widget should support all characters defined in the provided font - including for example Polish / extended Latin etc. The chosen example font ("Liberation ...") is of no significance and could be replaced by whatever you find useful. Please note that there is no guarantee whatsoever and that the work overall remains to be licensed as PyMuPDF itself (GNU AGPL 3.0 or commercial). |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm trying to use pymupdf to fill a pdf form . Initially I thought I got it... with sample data form text fields were filling nicely.
But then I've introduced polish letters into sample data (like ąęśćżź) - and this caused the filled data to be rendered outside text field (below it) - occluded / invisible (wouldn't noticed those if I haven't spotted the very tops of the letters) until I've clicked on it.
Is there a way to make it work?
The form itself has been created in OnlyOffice.
Edit: also I've noticed that if I opened the file filled with my pymupdf script the font used in the fields gets reset to Nimbus or Helvetica. In the fields where are polish letters it is Numbus.
I've added pymupdf-fonts package and tried forcing other fonts - but with no luck. I'm clearly doing something wrong.
Here's the function I'm using to fill the form:
Beta Was this translation helpful? Give feedback.
All reactions