diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2020-04-27 11:00:28 -0400 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2020-04-27 11:00:28 -0400 |
commit | 5ac24755485a5c1cc1cef084f08706246ee4f66c (patch) | |
tree | 13638e411abdea3c8935bff2650986025bde7cda | |
parent | d51f704fd8cbae03cd9b29fe103dd027d521ff04 (diff) | |
download | postgresql-5ac24755485a5c1cc1cef084f08706246ee4f66c.tar.gz postgresql-5ac24755485a5c1cc1cef084f08706246ee4f66c.zip |
Doc: render π more nicely in PDF output.
We need to select symbol font explicitly, or it comes out misaligned.
Alexander Lakhin, Tom Lane
Discussion: https://postgr.es/m/10598.1587928415@sss.pgh.pa.us
-rw-r--r-- | doc/src/sgml/func.sgml | 2 | ||||
-rw-r--r-- | doc/src/sgml/ref/pgbench.sgml | 2 | ||||
-rw-r--r-- | doc/src/sgml/stylesheet-fo.xsl | 5 |
3 files changed, 7 insertions, 2 deletions
diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml index b0afaebf728..692f78aa519 100644 --- a/doc/src/sgml/func.sgml +++ b/doc/src/sgml/func.sgml @@ -1365,7 +1365,7 @@ repeat('Pg', 4) <returnvalue>PgPgPgPg</returnvalue> <function>pi</function> ( ) <returnvalue>double precision</returnvalue> <?br?> - Approximate value of π + Approximate value of <phrase role="symbol_font">π</phrase> <?br?> <literal>pi()</literal> <returnvalue>3.141592653589793</returnvalue> diff --git a/doc/src/sgml/ref/pgbench.sgml b/doc/src/sgml/ref/pgbench.sgml index 58a2aa3bf20..c9a9f0e0e5f 100644 --- a/doc/src/sgml/ref/pgbench.sgml +++ b/doc/src/sgml/ref/pgbench.sgml @@ -1528,7 +1528,7 @@ SELECT 4 AS four \; SELECT 5 AS five \aset <row> <entry><literal><function>pi()</function></literal></entry> <entry>double</entry> - <entry>value of the constant PI</entry> + <entry>value of the constant <phrase role="symbol_font">π</phrase></entry> <entry><literal>pi()</literal></entry> <entry><literal>3.14159265358979323846</literal></entry> </row> diff --git a/doc/src/sgml/stylesheet-fo.xsl b/doc/src/sgml/stylesheet-fo.xsl index 6797e06a77c..2f2517d8ce6 100644 --- a/doc/src/sgml/stylesheet-fo.xsl +++ b/doc/src/sgml/stylesheet-fo.xsl @@ -101,6 +101,11 @@ <fo:block/> </xsl:template> +<!-- FOP needs us to be explicit about use of symbol font in some cases --> +<xsl:template match="phrase[@role='symbol_font']"> + <fo:inline font-family="{$symbol.font.family}"><xsl:value-of select="."/></fo:inline> +</xsl:template> + <!-- bug fix from <https://sourceforge.net/p/docbook/bugs/1360/#831b> --> <xsl:template match="varlistentry/term" mode="xref-to"> |