Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better font detection [Enable fontconfig support] #4

Open
ashutoshvarma opened this issue Jul 2, 2020 · 0 comments
Open

Better font detection [Enable fontconfig support] #4

ashutoshvarma opened this issue Jul 2, 2020 · 0 comments
Labels
enhancement New feature or request font topics related to font support help wanted Extra attention is needed

Comments

@ashutoshvarma
Copy link
Owner

For the PDF's that does not embed fonts (mostly Adobe Base-14 fonts as they are not required to embed as per PDF specification) in them we have to search for fonts in user's system.
The best way for that should be using fontconfig as xpdf-4.02 has fontconfig support already but disabled in libxpdf.

Why fontconfig support is disabled in libxpdf?
Because goal of libxpdf was to provide static library with minimum dependencies by including them statically. But for fontconfig, including it in a static library is pretty difficult (at least for me) as :

  • It requires a font.conf configuration file and without it spams the stdout with warnings.
  • Also the search location for this font.conf file must be hardcoded during build which would make pyxpdf wheels error prone.

Probable solutions:-

  • Include fontconfig statically in libxpdf and ship pyxpdf with it own custom font.conf which should work in all supported oses.
@ashutoshvarma ashutoshvarma added enhancement New feature or request help wanted Extra attention is needed font topics related to font support labels Jul 2, 2020
@ashutoshvarma ashutoshvarma changed the title Better installed font detection Better installed font detection [Enable fontconfig support] Aug 3, 2020
@ashutoshvarma ashutoshvarma changed the title Better installed font detection [Enable fontconfig support] Better font detection [Enable fontconfig support] Aug 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request font topics related to font support help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant