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

XFA - Support non-embedded fonts without a Widths entry #13644

Merged
merged 1 commit into from
Jun 28, 2021

Conversation

calixteman
Copy link
Contributor

  • some pdf use some fonts which are not embedded or they don't have any width array or don't have any css info (e.g. for standard fonts or Arial).
  • so add widths arrays for Liberation fonts in order to compute the ones for other fonts in using scale factors array.

@calixteman
Copy link
Contributor Author

/botio test

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Received

Command cmd_test from @calixteman received. Current queue size: 0

Live output at: http://54.67.70.0:8877/f34b0dd38ec0bb2/output.txt

@pdfjsbot
Copy link

From: Bot.io (Windows)


Received

Command cmd_test from @calixteman received. Current queue size: 0

Live output at: http://3.101.106.178:8877/6b9c9fde2338e24/output.txt

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Failed

Full output at http://54.67.70.0:8877/f34b0dd38ec0bb2/output.txt

Total script time: 29.34 mins

  • Font tests: Passed
  • Unit tests: Passed
  • Integration Tests: Passed
  • Regression tests: FAILED
  different ref/snapshot: 21
  different first/second rendering: 1

Image differences available at: http://54.67.70.0:8877/f34b0dd38ec0bb2/reftest-analyzer.html#web=eq.log

@pdfjsbot
Copy link

From: Bot.io (Windows)


Failed

Full output at http://3.101.106.178:8877/6b9c9fde2338e24/output.txt

Total script time: 34.11 mins

  • Font tests: Passed
  • Unit tests: Passed
  • Integration Tests: FAILED
  • Regression tests: FAILED
  different ref/snapshot: 23
  different first/second rendering: 1

Image differences available at: http://3.101.106.178:8877/6b9c9fde2338e24/reftest-analyzer.html#web=eq.log

*/

// Widths of glyphes in LiberationSans-BoldItalic.ttf.
const LiberationBoldItalicWidths = [
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it not be better to call this LiberationSansBoldItalicWidths, and similarly for the other fonts below, to reduce the risk that we'd need to rename everything in the future if e.g. support for serif Liberation fonts is added?

  - some pdf use some fonts which are not embedded or they don't have any width array or don't have any css info (e.g. for standard fonts or Arial).
  - so add widths arrays for Liberation fonts in order to compute the ones for other fonts in using scale factors array.
@calixteman calixteman merged commit 04dc902 into mozilla:master Jun 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants