Some of the Devnagri Fonts not being rendered properly
See original GitHub issueLink to PDF file: 2007-01-SB_CMYK.pdf
Configuration:
- Web browser and its version: Chrome (Version 51.0.2704.103 m) and Mozilla Firefox 47.0
- Operating system and its version: Windows 10 Pro
- PDF.js version: 1.5.355
- Is an extension: N/A
Steps to reproduce the problem:
- Go to https://mozilla.github.io/pdf.js/web/viewer.html
- Upload the attached PDF (2007-01-SB_CMYK.pdf) file to reproduce the error.
What is the expected behavior? I have attached correct display of the PDF file below which is showing up the text without any issue before being rendered by pdf.js
What went wrong? Some of the text are not being rendered properly. We are using SHREE-DEV Devnagri Fonts which are freely available at http://www.abstractfonts.com/search/shree-dev-0714 download for download. I have included the screenshot of the PDF file which is being rendered incorrectly.
Chrome Error Console Output:
Warning: Failed to load font "g_d0_f2": SyntaxError: Invalid font data in ArrayBuffer. pdf.js:277
Warning: Failed to load font "g_d0_f4": SyntaxError: Invalid font data in ArrayBuffer. pdf.js:277
Warning: Failed to load font "g_d0_f6": SyntaxError: Invalid font data in ArrayBuffer. pdf.js:277
Warning: Failed to load font "g_d0_f10": SyntaxError: Invalid font data in ArrayBuffer. pdf.js:277
Warning: Failed to load font "g_d0_f11": SyntaxError: Invalid font data in ArrayBuffer. pdf.js:277
Issue Analytics
- State:
- Created 7 years ago
- Comments:7 (2 by maintainers)
Top Results From Across the Web
Devanagari font not rendered correctly · Issue #3191 - GitHub
I am trying to print Devanagari text on the image. The text is printing on the image. But, it is not appearing the...
Read more >Incorrect rendering/display of Devanagari fonts in browsers
To render any language text, font should support that text. Default fonts of Ubuntu does not render Devanagari correctly. In order to correctly...
Read more >Emacs 27.2 not rendering Devanagari fonts properly
I am having problems with Devanagari fonts in Emacs 27.2. I am using the Noto Sans Devanagari font to render the devanagari unicode...
Read more >Unicode font rendering broken with Devanagari fonts?
Hi there, I am very interested in rendering Unicode text involving Devanagari characters (used for languages like Hindi, Sanskrit, etc.).
Read more >Devanagari ( Indian ) fonts are not being rendered by browsers
Check database setting for UTF-8 for other languages. · Yes, I've already set Database Character set to AL32UTF · You have to make...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
A more complete error message, from the Firefox console:
The errors thus point to the
glyf
data validation in OTS, in particular src/glyf.cc#L101-L108.Interestingly, if we called
sanitizeGlyphLocations
withhintsValid = false
, see src/core/fonts.js#L1644-L1646, this would just fix things. I’m wondering ifsanitizeTTPrograms
, see src/core/fonts.js#L2084, is somehow failing to detect that the fonts aren’t well formed!?Done: Created ticket #8960