From: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
---|---|
To: | Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-docs(at)lists(dot)postgresql(dot)org |
Subject: | Re: Rendering pi more nicely in PDF |
Date: | 2020-04-29 21:23:31 |
Message-ID: | 20200429212331.GA13762@alvherre.pgsql |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-docs |
On 2020-Apr-29, Peter Eisentraut wrote:
> To use a different font, you have to (a) pick one, and (b) install it
> locally when you build the PDFs.
>
> My proposal is to use the DejaVu fonts, which are open source and easily
> available for common operating systems. (Arguably, they also give the
> documentation a slightly fresher look.)
>
> The attached patch implements this. You just have to install the fonts
> somehow. Red Hat and Debian should have packages for this. We should write
> instructions for this in any case.
It's not easy to build the PDF with this. There's a stray > in fop.xml.
After fixing that, I get a warning about fontbox java lib not being installed.
OK, I can install libfontbox-java and that one disappears. Then there's
this other warning:
[warning] /usr/bin/fop: JVM flavor 'sun' not understood
which seems to be innocuous. The build it still dies because of a CFF
type1 something or other:
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/fontbox/cff/CFFType1Font
at org.apache.fop.fonts.truetype.OTFFile.isType1(OTFFile.java:151)
After a quick search I found this bug
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=584472
which suggests that I patch /usr/bin/fop to find_jars in "fontbox2"
instead of fontbox. OK, remove package libfontbox-java, patch the
script, try again. Now it seems to work, and the doc looks pretty.
But apparently it's not sufficient -- the new font is not used
everywhere. For example footnotes seem to use a different font than the
main body of text. (I altered the fontname to Gentium, which I like
better, and uses a different glyph for "g" which is easy to spot ... and
notably absent in footnote in page 5 under 1.4 Accessing a Database.)
I +1 the idea of using a more complete font if it means we can render
contributor names better, though :-)
--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Yuri Astrakhan | 2020-04-29 21:34:13 | Re: Direct links to edit documentation |
Previous Message | Tom Lane | 2020-04-29 20:44:57 | Re: Rendering pi more nicely in PDF |