ajrcarey / pdfium-render

A high-level idiomatic Rust wrapper around Pdfium, the C++ PDF library used by the Google Chromium project.
https://crates.io/crates/pdfium-render
Other
364 stars 59 forks source link

Attempt to add a subset of the font library to reduce the size of the PDF #133

Closed 1000374 closed 10 months ago

1000374 commented 10 months ago

such as,

  1. add "你好", then add "abc", each time extract the character subset and then call FPDFText_ LoadFont
  2. "你好abc", get character subset and then call FPDFText_ LoadFont file 2 is much larger than file 1 in size so I don't know how to use it,any suggestions would be greatly appreciated
ajrcarey commented 10 months ago

Hi @1000374 , thank you for reporting the issue. Pdfium doesn't provide any control (that I am aware of) over which glyphs of a font are embedded in the file. Can you provide some sample code for your #1 and #2 that demonstrate the difference in file size?

ajrcarey commented 10 months ago

As there have been no further comments and I am not clear on what you are asking, I will shortly close the issue.

ajrcarey commented 10 months ago

Closing the issue as insufficient information as been provided in order to proceed.