<html>
<head>
<base href="https://bugs.freedesktop.org/" />
</head>
<body><span class="vcard"><a class="email" href="mailto:jason@aquaticape.us" title="Jason Crain <jason@aquaticape.us>"> <span class="fn">Jason Crain</span></a>
</span> changed
<a class="bz_bug_link
bz_status_NEW "
title="NEW - Poppler fails to display pdf correctly"
href="https://bugs.freedesktop.org/show_bug.cgi?id=93299">bug 93299</a>
<br>
<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>What</th>
<th>Removed</th>
<th>Added</th>
</tr>
<tr>
<td style="text-align:right;">Attachment #120735 is obsolete</td>
<td>
</td>
<td>1
</td>
</tr></table>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - Poppler fails to display pdf correctly"
href="https://bugs.freedesktop.org/show_bug.cgi?id=93299#c5">Comment # 5</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - Poppler fails to display pdf correctly"
href="https://bugs.freedesktop.org/show_bug.cgi?id=93299">bug 93299</a>
from <span class="vcard"><a class="email" href="mailto:jason@aquaticape.us" title="Jason Crain <jason@aquaticape.us>"> <span class="fn">Jason Crain</span></a>
</span></b>
<pre>Created <span class=""><a href="attachment.cgi?id=121066" name="attach_121066" title="Fallback to looking up glyph by Unicode code point">attachment 121066</a> <a href="attachment.cgi?id=121066&action=edit" title="Fallback to looking up glyph by Unicode code point">[details]</a></span> <a href='page.cgi?id=splinter.html&bug=93299&attachment=121066'>[review]</a>
Fallback to looking up glyph by Unicode code point
Sorry about the crash. That's what I get for testing with a subset of
documents that happened to not have any CID fonts. :/
This version of the patch fixes the crash / invalid cast by checking for and
filtering out CID fonts. I think the CID case is already taken care of by
requesting the language from fontconfig. And I'm not completely sure how the
CID charcode to unicode stuff works, but it looks like some of the maps are
thousands of entries long, which would make this approach infeasable for CID
fonts anyway.
While doing more testing, I also noticed that the previous patch caused some
documents to have less appropriate fonts substituted. An italic, bold, or
light font might be replaced with a more generic font because it had better
unicode coverage, even if the document didn't actually use any of the
characters. To prevent that, this patch adds a dependency on icu to look up
the unicode character class and only add the character if it's alphabetic.
This also doesn't use the character set for a ZapfDingbats or Symbol font,
because some documents used WinAnsiEncoding for these, or if fontconfig was
able to find a font with the exact name as the document requested, such as
MTExtra or ComicSansMS.
Also fixed a problem where because the buildFcPattern function modifies the
font name from it's arguments in place, it may not work right if it's called a
second time with the same arguments and can lose the bold/italic/etc modifiers
from the font.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>