pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tilman Hausherr <THaush...@t-online.de>
Subject Re: How do I specify the google noto font with printed
Date Thu, 25 May 2017 08:12:05 GMT
Am 25.05.2017 um 08:01 schrieb Rock Lin:
> Hi Sir:
> I used the PDDocument.load(PdfInputStream) to load a PDF File.
>
> And I want to print this PDF use google noto
> font(NotoSansCJKtc-Regular.otf).(The PDF has many chinese word)
>
> How did I do?

You can't, at least not out of the box. It wouldn't make sense, because 
a PDF decides itself what fonts are to be used. If the fonts are not 
embedded, then you should get the missing font and install it on your 
system. When fonts are missing, PDFBox tries to map to an existing font.

Alternatively, set your own fontmapper. To do this, download the source 
code and have a look at the implementation of FontMapperImpl. Create 
your own and install it with FontMappers.set(new MyNewFontMapper());

Tilman

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: users-help@pdfbox.apache.org


Mime
View raw message