0

I want to added some form in a PDF template using Acrobat, I'm not allow to modify that template. Since labels in that template are in a font called STXiHei, I want to make my forms the same. However I cannot find this font in the choosing list.

This really confused me because I'm sure my Mac installed this font and can use it in Word or other applications. Besides, in the edit view of Acrobat I can also using this font in any text box. I just can't use this in a text form.

I'm using Acrobat Pro XI on Mac, Can anyone help?

  • It looks like that font can not be fully embedded, but only subsetted. In order to use a font for form fields, it must be fully embedded (otherwise, you may end up in characters not available). – Max Wyss Dec 11 '15 at 7:50
  • @MaxWyss I think you are right, I checked the document property and found this font is subsetted embedded. What I really want to do is filling the forms programmatically and then re-subset-embed this font again. Now I'm using Java and iText trying to achieve this, any hints? BTW, now your comment has already being a correct answer, answer me and I'll accept. – Elderry Dec 11 '15 at 9:10
0

Based on a comment, with additional musings…

It looks like that font can not be fully embedded, but only subsetted. In order to use a font in form fields, that font must be fully embedded (otherwise, you may end up with characters not available). From the font's view, it must be fully embeddable (meaning that the according flag has to be set, if it is a TrueType or an OpenType font; PostScript fonts don't have embedding flags).

Now, if the fields are to be flattened anyway, it might be a more suitable approach to read out their coordinates and then to place the text at the appropriate location, which makes it part of the base document, and the font can be embedded subsetted (because the characters needed are known, and won't change). I am not sufficiently familiar with iText to determine whether that is possible, but I am sure that information can be found (or given in another answer).

I am quite positive that the approach mentioned above can be implemented using pdflib (even if that info is quite old).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.