poppler cannot parse font weight "Medium"

Bug #769827 reported by Nobuto Murata on 2011-04-24
20
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Poppler
Fix Released
Medium
poppler (Ubuntu)
Medium
Unassigned
Lucid
Medium
Unassigned
Natty
Medium
Unassigned
Oneiric
Medium
Unassigned

Bug Description

The poppler library cannot parse font weight "Medium". Therefore in Japanese(ja) locale, characters which are not font-embedded but specified as "GothicBBB" are shown as squares and not readable.

GothicBBB is widely used as Japanese sans-serif(gothic) font. It has the full name "GothicBBB-Medium-Identity-{H,V}" in properties window on such as Evince. But poppler library cannot parse "Medium" string, so does not hit <string>GothicBBB</string> in fontconfig settings on /etc/fonts/conf.d/69-language-selector-ja-jp.conf.

On the other hand, Ryumin which is widely used as Japanese serif(mincho) font has the name "Ryumin-Light-Identity-{H,V}", but does hit <string>Ryumin</string>.

How to reproduce (assuming that you're not starting in Japanese locale):
 1. Run Language Selector and install Japanese support.
 2. sudo apt-get install poppler-data
 3. sudo fontconfig-voodoo -s ja_JP
 4. Open attached PDF file:
    https://bugs.launchpad.net/ubuntu/+source/poppler/+bug/769827/+attachment/2086089/+files/g_non_emb.pdf

Expected:
 all characters are showed properly
 https://bugs.launchpad.net/ubuntu/+source/poppler/+bug/769827/+attachment/2086087/+files/expected.png

Actual:
 upper-right characters which are specified as GothicBBB are showed as squares
 https://bugs.launchpad.net/ubuntu/+source/poppler/+bug/769827/+attachment/2086084/+files/actual.png

ProblemType: Bug
DistroRelease: Ubuntu 11.04
Package: poppler-utils 0.16.4-0ubuntu1
ProcVersionSignature: Ubuntu 2.6.38-8.42-generic 2.6.38.2
Uname: Linux 2.6.38-8-generic i686
Architecture: i386
Date: Sun Apr 24 10:09:07 2011
LiveMediaBuild: Ubuntu 11.04 "Natty Narwhal" - Release i386 (20110423)
ProcEnviron:
 LANGUAGE=ja_JP:en
 LANG=ja_JP.UTF-8
 SHELL=/bin/bash
SourcePackage: poppler
UpgradeStatus: No upgrade log present (probably fresh install)

Nobuto Murata (nobuto) wrote :
Changed in poppler (Ubuntu):
assignee: nobody → Nobuto MURATA (nobuto)
status: New → In Progress
Nobuto Murata (nobuto) wrote :
Nobuto Murata (nobuto) wrote :

Sample PDF attached.
Thanks Hiroshi Chonan for providing this on https://wiki.ubuntulinux.jp/Develop/Natty/Evince.

description: updated
Nobuto Murata (nobuto) wrote :
Nobuto Murata (nobuto) wrote :
Changed in poppler (Ubuntu):
assignee: Nobuto MURATA (nobuto) → nobody
status: In Progress → Confirmed
tags: added: patch
Rolf Leggewie (r0lf) wrote :

I can confirm the problem in lucid. Japanese locale is not necessary.

Nobuto Murata (nobuto) wrote :

I have tried to forward this to upstream, but already reported as https://bugs.freedesktop.org/show_bug.cgi?id=36474. It mainly handles other problems (properly fall back to Japanese font when font does not have Japanese glyphs), but contains my patch too. What should I do?

Rolf Leggewie (r0lf) wrote :

Nobuto-San, I think you've already done all you can (and more). The next steps that I see are to get the patch applied to natty and then hopefully backported to at least lucid. But that's out of your and my reach, we need to wait for sponsors to pick it up which I'm sure they will soon.

Changed in poppler (Ubuntu):
importance: Undecided → Medium
milestone: none → ubuntu-11.04
status: Confirmed → Triaged
Michael Terry (mterry) on 2011-04-25
description: updated
Michael Terry (mterry) wrote :

I'm dropping the milestone and nominating for natty as an SRU because this is too late to make it into natty proper. I'll request that this be put into oneiric once that opens and make the bug changes for an SRU for natty.

I have confirmed that the patch works. Nobuto, the only change I would suggest is that you also run update-maintainer in your package directory to make sure that the Maintainer field is accurate when we make Ubuntu changes in a package. Of course, that wasn't your fault, but Martin Pitt's when he first diverged.

Changed in poppler (Ubuntu):
milestone: ubuntu-11.04 → none
Michael Terry (mterry) wrote :

Here is a version suitable for natty-proposed (just version and pocket change). I don't have upload rights for the poppler package, so I will ask that a core-dev please upload this for me to natty-proposed.

Sebastien Bacher (seb128) wrote :

there is an upload in the natty-proposed queue so setting to fix commited

Changed in poppler (Ubuntu Natty):
status: Triaged → Fix Committed
Changed in poppler (Ubuntu Oneiric):
status: New → Triaged
importance: Undecided → Medium

Accepted poppler into natty-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

tags: added: verification-needed
Nobuto Murata (nobuto) wrote :

poppler 0.16.4-0ubuntu1.1/natty-proposed works fine.

tags: added: verification-done
removed: verification-needed
Changed in poppler (Ubuntu Lucid):
status: New → Confirmed
importance: Undecided → Medium
Nobuto Murata (nobuto) wrote :

debdiff for Lucid SRU. I will set ubuntu-sponsors subscribed again.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package poppler - 0.16.4-0ubuntu1.1

---------------
poppler (0.16.4-0ubuntu1.1) natty-proposed; urgency=low

  * debian/patches/11_set-font-weight-medium.patch: added
    - set FC_WEIGHT_MEDIUM when the font name contains "Medium", LP: #769827
 -- Nobuto MURATA <email address hidden> Mon, 25 Apr 2011 12:11:24 -0400

Changed in poppler (Ubuntu Natty):
status: Fix Committed → Fix Released
Martin Pitt (pitti) wrote :

Copied to oneiric as well.

Changed in poppler (Ubuntu Oneiric):
status: Triaged → Fix Released
Stéphane Graber (stgraber) wrote :

Made sure the patch also applies to lucid's codebase and then sponsored Nobuto MURATA's SRU to lucid-proposed.
Will show up once a SRU team member approves it.

Changed in poppler (Ubuntu Lucid):
status: Confirmed → Fix Committed
Martin Pitt (pitti) wrote :

Accepted poppler into lucid-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

tags: removed: verification-done
tags: added: verification-needed
Rolf Leggewie (r0lf) wrote :

patch works fine in lucid

tags: added: verification-done
removed: verification-needed
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package poppler - 0.12.4-0ubuntu5.2

---------------
poppler (0.12.4-0ubuntu5.2) lucid-proposed; urgency=low

  * debian/patches/12_set-font-weight-medium.patch: added
    - set FC_WEIGHT_MEDIUM when the font name contains "Medium", LP: #769827
 -- Nobuto MURATA <email address hidden> Tue, 26 Apr 2011 09:58:25 +0900

Changed in poppler (Ubuntu Lucid):
status: Fix Committed → Fix Released
Nobuto Murata (nobuto) wrote :

The patch was committed in upstream as
http://cgit.freedesktop.org/poppler/poppler/commit/?id=e2fa8a2ca8459d19c0f9dca445a2399b9a3d483d
and as a part of the bug
https://bugs.freedesktop.org/show_bug.cgi?id=36474

The patch in Ubuntu can be dropped if upstream does a new release.

Changed in poppler:
importance: Unknown → Medium
status: Unknown → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.