Gentoo Archives: gentoo-user

From: thelma@×××××××××××.com
To: gentoo-user@l.g.o, ash@××××××××××.uk
Subject: Re: [gentoo-user] evince doesn't display check-mark symbol
Date: Thu, 21 May 2020 22:21:32
Message-Id: fc3bf331-fe92-2834-5305-10e711ea0e66@sys-concept.com
In Reply to: Re: [gentoo-user] evince doesn't display check-mark symbol by Ashley Dixon
1 On 05/20/2020 09:08 PM, Ashley Dixon wrote:
2 > On Wed, May 20, 2020 at 08:12:54PM -0600, thelma@×××××××××××.com wrote:
3 >> I think so too, that that is why I'm puzzled.
4 >> Here is the form.
5 >
6 > Thanks for attaching the document, but it's huge ! I placed the emphasis on
7 > _minimal_ for a reason. ;-)
8 >
9 > Anyway, I'm able to replicate this, and I'd say it's likely to be a bug in
10 > Evince. Using GhostScript [1] to retroactively embed all the fonts allows
11 > Evince to render it without issue, pointing to an issue causing it to avoid
12 > loading external fonts.
13 >
14 > gs \
15 > -dCompatibilityLevel=1.4 \
16 > -dPDFSETTINGS=/screen \
17 > -dCompressFonts=true \
18 > -dSubsetFonts=true \
19 > -dNOPAUSE \
20 > -dBATCH \
21 > -sDEVICE=pdfwrite \
22 > -sOutputFile=form-fixed.pdf \
23 > -c ".setpdfwrite <</NeverEmbed [ ]>> setdistillerparams" \
24 > -f form-original.pdf
25 >
26 > Although, having to do this on all your documents is obviously suboptimal, and
27 > also can make them quite a bit larger. Strangely, after testing on my Manjaro
28 > QEMU virtual machine, everything behaves correctly; the P.D.F.\ without embedded
29 > Dingbats renders correctly.
30 >
31 > [Solution]
32 >
33 > Evince is substituting ZapfDingbats with another font. On my system, this is
34
35 > Liberation Sans Regular (Properties->Fonts->ZapfDingbats). This means that
36 > Evince cannot find the font "ZapfDingbats". To rectify this, download "ITC Zapf
37 > Dingbats" from [2] and unzip the two files into ~/.local/share/fonts or
38 > /usr/share/fonts.
39 >
40 > However, "ZapfDingbats" and "ITC Zapf Dingbats" have a slight name mismatch,
41 > which will still cause Evince to substitute it with an unsuitable alternative.
42 > Fontconfig allows you to alias fonts using its standard XML configuration
43 > method. Add the following to /etc/fonts/local.conf (create the file if it does
44 > not exist):
45 >
46 > <?xml version="1.0"?>
47 > <!DOCTYPE fontconfig SYSTEM "fonts.dtd">
48 > <fontconfig>
49 > <alias>
50 > <family>ZapfDingbats</family>
51 > <prefer><family>ITC Zapf Dingbats</family></prefer>
52 > <default><family>fixed</family></default>
53 > </alias>
54 > </fontconfig>
55 >
56 > This will cause Evince to load the document correctly. You might have to run
57 > `fc-cache` after you've created the <alias> stanza, although I doubt it.
58 >
59 > Does this fix it ?
60 >
61 > [1] https://stackoverflow.com/a/2981689
62 > [2] https://freefontsfamily.com/download/itc-zapf-dingbats
63 >
64
65 Hi Ashley,
66
67 Thank you for the hint. I unzip the "ITC Zapf Dingbats.zip" to
68 /usr/share/fonts/itc-zapf-dingbats
69
70 and created as you suggested: /etc/fonts/local.conf with the content
71 above and the "check-mark" is showing perfectly.
72
73 Thank you for the solution!
74
75 Regards,
76 Thelma

Replies

Subject Author
Re: [gentoo-user] evince doesn't display check-mark symbol Ashley Dixon <ash@××××××××××.uk>