Small issue in online devel documentation build

Started by Fabien COELHOalmost 9 years ago56 messages
#1Fabien COELHO
coelho@cri.ensmp.fr

When consulting the online "devel" documentation, for instance for
"pgbench":

https://www.postgresql.org/docs/devel/static/pgbench.html

Unordered lists <ul> are shown in bold, as can be seen in the -M option
and in the description of random functions. This is because "ul" is in
class "c2" in the html:

<ul class="itemizedList c2"> ...

I cannot reproduce this when generating html for head, so I gather that
the web-site doc generation must be based on a different transformations.

My point is that some xsl file should be fixed somewhere, probably, to
avoid that.

--
Fabien.

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#2Robert Haas
robertmhaas@gmail.com
In reply to: Fabien COELHO (#1)
Re: Small issue in online devel documentation build

On Thu, Feb 16, 2017 at 1:05 PM, Fabien COELHO <coelho@cri.ensmp.fr> wrote:

When consulting the online "devel" documentation, for instance for
"pgbench":

https://www.postgresql.org/docs/devel/static/pgbench.html

Unordered lists <ul> are shown in bold, as can be seen in the -M option and
in the description of random functions. This is because "ul" is in class
"c2" in the html:

<ul class="itemizedList c2"> ...

I cannot reproduce this when generating html for head, so I gather that the
web-site doc generation must be based on a different transformations.

My point is that some xsl file should be fixed somewhere, probably, to avoid
that.

Yeah, I noticed this too, and I think Ashutosh also complained about
it on another thread. It's pretty annoying - I hope somebody can
figure out the cause and fix it. It seems to be only affecting the
development docs.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#3Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Robert Haas (#2)
Re: Small issue in online devel documentation build

My point is that some xsl file should be fixed somewhere, probably, to avoid
that.

Yeah, I noticed this too, and I think Ashutosh also complained about
it on another thread. It's pretty annoying - I hope somebody can
figure out the cause and fix it. It seems to be only affecting the
development docs.

My 0.02€:

After some random digging, it seems that the documentation files are
loaded from provided tarballs by a script: "tools/docs/docload.py"
maintained in "pgweb.git". Maybe this is run from some cron.

AFAICS from the script, the provided tarballs contains the generated html
that someone/something has already generated and put somewhere. I have
found no clear clue about who, where and when. However I would bet that
"Magnus Hagander" and "Dave Page" know, given that they commits suggest
that they are maintaining the site:-)

The load script passes the doc through "tidy" with some options, and
registers the pages into a database probably for django. I doubt this
would change the ul class.

--
Fabien.
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#4Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Fabien COELHO (#3)
Re: [HACKERS] Small issue in online devel documentation build

On 2/16/17 15:35, Fabien COELHO wrote:

After some random digging, it seems that the documentation files are
loaded from provided tarballs by a script: "tools/docs/docload.py"
maintained in "pgweb.git". Maybe this is run from some cron.

AFAICS from the script, the provided tarballs contains the generated html
that someone/something has already generated and put somewhere. I have
found no clear clue about who, where and when. However I would bet that
"Magnus Hagander" and "Dave Page" know, given that they commits suggest
that they are maintaining the site:-)

The load script passes the doc through "tidy" with some options, and
registers the pages into a database probably for django. I doubt this
would change the ul class.

Can someone from the web site team look into this?

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#5Magnus Hagander
magnus@hagander.net
In reply to: Peter Eisentraut (#4)
Re: [HACKERS] Small issue in online devel documentation build

On Sat, Feb 18, 2017 at 1:45 AM, Peter Eisentraut <
peter.eisentraut@2ndquadrant.com> wrote:

On 2/16/17 15:35, Fabien COELHO wrote:

After some random digging, it seems that the documentation files are
loaded from provided tarballs by a script: "tools/docs/docload.py"
maintained in "pgweb.git". Maybe this is run from some cron.

AFAICS from the script, the provided tarballs contains the generated html
that someone/something has already generated and put somewhere. I have
found no clear clue about who, where and when. However I would bet that
"Magnus Hagander" and "Dave Page" know, given that they commits suggest
that they are maintaining the site:-)

The load script passes the doc through "tidy" with some options, and
registers the pages into a database probably for django. I doubt this
would change the ul class.

Can someone from the web site team look into this?

Sure.

The script in question loads the docs from the build tarballs - we read
whatever goes in the snapshot tarballs on the site and load that in the db.

The developer docs, and the snapshot tarballs, run as a final step of the
buildfarm job on guaibasaurus.

The toolchain used previously (9.6) generates this code:
<P

Protocol to use for submitting queries to the server:

<P

</P
</P><UL
<LI
<P
<TT

CLASS="LITERAL"

simple</TT
: use simple query protocol.</P
</LI
<LI
<P
<TT

CLASS="LITERAL"

extended</TT
: use extended query protocol.</P
</LI
<LI
<P
<TT

CLASS="LITERAL"

prepared</TT
: use extended query protocol with prepared statements.</P
</LI
</UL

(yes, including all the horrible newlines in the middle of tags and
whatnot, but there's nothing new about that)

The toolchain used for dev (10) generates this code:
<p> Protocol to use for submitting queries to the server:
</p><div class="itemizedlist"><ul class="itemizedlist"
style="list-style-type: disc; "><li class="listitem"><p><code
class="literal">simple</code>: use simple query protocol.</p></li><li
class="listitem"><p><code class="literal">extended</code>: use extended
query protocol.</p></li>

So the HTML generated is completely different. The old one didn't even use
unnumbered lists.

Is that intentional?

I for one did not realize the new toolchain created completely different
structure HTML. I know we applied a41a4cc74be8c34f7f8f1c4ec03b5dc01db06c17
to handle changes from the new toolchain, but that won't cover cases where
the whole structure is different.

In this particular case, the boldness comes from the c2 class as indicated
earlier. But that class has always been bold.

Might it just be that somebody has to actually go over the new structure of
the docs and provide the appropriate CSS rules? Or is something wrong with
the actual building of them as they give a completely different structure?

As for the reproduction - the snapshot tarballs are built by the buildfarm
animal guaibasaurus, which is on Debian Jessie. Could the inability to
reproduce be because of platform differences in the docs tools?

--
Magnus Hagander
Me: http://www.hagander.net/
Work: http://www.redpill-linpro.com/

#6Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Magnus Hagander (#5)
Re: [HACKERS] Small issue in online devel documentation build

Hello Magnus,

The toolchain used previously (9.6) generates this code:
<UL

<LI
<P
<TT

CLASS="LITERAL"

simple</TT
: use simple query protocol.</P

[...]

(yes, including all the horrible newlines in the middle of tags and
whatnot, but there's nothing new about that)

Yes this is the "old" html generation with jade, which has been replaced
by some xsltproc-based html generation. Why not.

The toolchain used for dev (10) generates this code:

<p> Protocol to use for submitting queries to the server:
</p><div class="itemizedlist"><ul class="itemizedlist"
style="list-style-type: disc; "><li class="listitem"><p><code
[...]

Yes, that the output I also have, which is somehow fine although verbose.
In particular, there is no "c2" class involved in "ul" above...

So the HTML generated is completely different. The old one didn't even use
unnumbered lists.

??? AFAICS there is a <UL> in the first 9.6 extract above... the
difference is about the added class, style & div... but the structure
seems to be basically the same.

I for one did not realize the new toolchain created completely different
structure HTML. I know we applied a41a4cc74be8c34f7f8f1c4ec03b5dc01db06c17
to handle changes from the new toolchain, but that won't cover cases where
the whole structure is different.

I'm not sure it is that different, but there seems to be side effect at
some stages when the doc files are integrated into the web site.

In this particular case, the boldness comes from the c2 class as indicated
earlier. But that class has always been bold.

Probably. The question is rather why is the ul in this class on the
website, while it is not in the raw generated file? What adds it?

Might it just be that somebody has to actually go over the new structure of
the docs and provide the appropriate CSS rules? Or is something wrong with
the actual building of them as they give a completely different structure?

I'm unsure about "completely different", see above.

As for the reproduction - the snapshot tarballs are built by the buildfarm
animal guaibasaurus, which is on Debian Jessie. Could the inability to
reproduce be because of platform differences in the docs tools?

I regenerated the 10 doc on a jessie host with the new xsltproc-based
toolchain and got the same result as what you outline above, in particular
no mention of "c2".

So my guess is that it would be enough not to add this c2 class to ul to
avoid boldness.

Now the actual web pages is clearly a reprocessing of the generated xml,
so this c2 get added between the raw xhtml documentation that one can
reproduce and the web-page xml where there are specific headers for
navigation, as well as some heavy reindentation.

The script on pgweb.git suggest that a "tidy" thing is called on the xml
which is probably responsible for the reindentation, but maybe there are
other xslt or misc tools involved which are not accessible and contribute
to the final result?

--
Fabien.

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#7Magnus Hagander
magnus@hagander.net
In reply to: Fabien COELHO (#6)
Re: [HACKERS] Small issue in online devel documentation build

On Sat, Feb 18, 2017 at 1:44 PM, Fabien COELHO <coelho@cri.ensmp.fr> wrote:

Hello Magnus,

The toolchain used previously (9.6) generates this code:

<UL

<LI
<P
<TT

CLASS="LITERAL"

simple</TT
: use simple query protocol.</P

[...]

(yes, including all the horrible newlines in the middle of tags and
whatnot, but there's nothing new about that)

Yes this is the "old" html generation with jade, which has been replaced
by some xsltproc-based html generation. Why not.

The toolchain used for dev (10) generates this code:

<p> Protocol to use for submitting queries to the server:
</p><div class="itemizedlist"><ul class="itemizedlist"
style="list-style-type: disc; "><li class="listitem"><p><code
[...]

Yes, that the output I also have, which is somehow fine although verbose.
In particular, there is no "c2" class involved in "ul" above...

Ah, that is correct. I thought I could see it there, but turns out that no,
I cannot :) I was clearly not awake. My apologies.

It turns out the "c2" class is added by tidy. The reason is this:
http://api.html-tidy.org/tidy/quickref_5.0.0.html#clean

There was a reason this was needed on the old docs. I honestly don't
remember what it was though, but it was needed (but many things were needed
on that source).

Turning if off makes that page work. It might break pages elsewhere though.

I've removed the flag for the devel docs build for now (or - for any XML
based docs build). I've also forced another docs load, so the results can
be checked.

Let's see if that breaks something else...

--
Magnus Hagander
Me: http://www.hagander.net/
Work: http://www.redpill-linpro.com/

#8Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Magnus Hagander (#7)
Re: [HACKERS] Small issue in online devel documentation build

Hello Magnus,

It turns out the "c2" class is added by tidy. The reason is this:
http://api.html-tidy.org/tidy/quickref_5.0.0.html#clean

I've removed the flag for the devel docs build for now (or - for any XML
based docs build). I've also forced another docs load, so the results can
be checked.

Indeed, thanks, now it looks great... under firefox at least.

Another issue in the new HTML documentation, this time not related to the
web site. Under chrome there are some strange font size effects on
options, for instance with this HTML in "app-psql.html":

<span class="term">
<code class="option">-f
<em class="replaceable"><code>filename</code></em>
</code>
<br>
</span>

For previous versions, the following html was generated:

<tt class="OPTION">-f <tt class="REPLACEABLE c2">filename</tt></tt>

The filename in the newer html appears much larger under chrome, seemingly
because of the <code> within a <code>. Maybe a bug in chrome CSS
interpretation, because CSS on code seems to indicate "font-size: 1.3em",
but it seems to do 1.3**2 instead for "filename"... However it does not do
that elsewhere so it may not be that simple...

Basically it looks ok under chrome if in the initial sgml file there is:

<term><option>-s</option> <replaceable>scale_factor</></term>

(replaceable is out of option)

But bad on:

<term><option>--tablespace=<replaceable>tablespace</replaceable></option></term>

(replaceable is in the option), because the size change is somehow applied
twice.

The docbook doc says that "replaceable" is a children of "option", which
seems to suggest that this nested usage is legit... but it may be buggy as
well.

This may be fixed/worked around in several places:

1. html generation could be clever enough not to nest "code" tags?
or generate tt tags instead as was done before?

I have not found where this transformation is defined, probably
somewhere within "docbook"...

2. avoid replaceable within option in initial sgml files
=> many changes, will reappear if someone forgets.

3. some more post-processing tidying could be done
hmmm:-(

4. chrome should be repaired if there is indeed a bug...

--
Fabien.

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#9Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Fabien COELHO (#8)
1 attachment(s)
Re: [pgsql-www] Small issue in online devel documentation build

<span class="term">
<code class="option">-f
<em class="replaceable"><code>filename</code></em>
</code>
<br>
</span>

The filename in the newer html appears much larger under chrome, seemingly
because of the <code> within a <code>. Maybe a bug in chrome CSS
interpretation, because CSS on code seems to indicate "font-size: 1.3em", but
it seems to do 1.3**2 instead for "filename"... However it does not do that
elsewhere so it may not be that simple...

2. avoid replaceable within option in initial sgml files
=> many changes, will reappear if someone forgets.

I wrote a few lines of perl to move replaceable out of option and did some
manual editing is special cases, the resulting simple 359 changes is
attached.

--
Fabien.

Attachments:

doc-replaceable.patchtext/x-diff; name=doc-replaceable.patchDownload
diff --git a/doc/src/sgml/ref/clusterdb.sgml b/doc/src/sgml/ref/clusterdb.sgml
index 67582fd..6256508 100644
--- a/doc/src/sgml/ref/clusterdb.sgml
+++ b/doc/src/sgml/ref/clusterdb.sgml
@@ -122,8 +122,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-t <replaceable class="parameter">table</replaceable></></term>
-      <term><option>--table=<replaceable class="parameter">table</replaceable></></term>
+      <term><option>-t</> <replaceable class="parameter">table</></term>
+      <term><option>--table=</><replaceable class="parameter">table</></term>
       <listitem>
        <para>
         Cluster <replaceable class="parameter">table</replaceable> only.
@@ -173,8 +173,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the server is
@@ -185,8 +185,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP port or local Unix domain socket file
@@ -197,8 +197,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable class="parameter">username</replaceable></></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></></term>
+      <term><option>-U</> <replaceable class="parameter">username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as.
@@ -243,7 +243,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--maintenance-db=<replaceable class="parameter">dbname</replaceable></></term>
+      <term><option>--maintenance-db=</><replaceable class="parameter">dbname</></term>
       <listitem>
        <para>
          Specifies the name of the database to connect to discover what other
diff --git a/doc/src/sgml/ref/createdb.sgml b/doc/src/sgml/ref/createdb.sgml
index c363bd4..f3ef345 100644
--- a/doc/src/sgml/ref/createdb.sgml
+++ b/doc/src/sgml/ref/createdb.sgml
@@ -86,8 +86,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-D <replaceable class="parameter">tablespace</replaceable></></term>
-      <term><option>--tablespace=<replaceable class="parameter">tablespace</replaceable></></term>
+      <term><option>-D</> <replaceable class="parameter">tablespace</></term>
+      <term><option>--tablespace=</><replaceable class="parameter">tablespace</></term>
       <listitem>
        <para>
         Specifies the default tablespace for the database. (This name
@@ -108,8 +108,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-E <replaceable class="parameter">encoding</replaceable></></term>
-      <term><option>--encoding=<replaceable class="parameter">encoding</replaceable></></term>
+      <term><option>-E</> <replaceable class="parameter">encoding</></term>
+      <term><option>--encoding=</><replaceable class="parameter">encoding</></term>
       <listitem>
        <para>
         Specifies the character encoding scheme to be used in this
@@ -121,8 +121,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-l <replaceable class="parameter">locale</replaceable></></term>
-      <term><option>--locale=<replaceable class="parameter">locale</replaceable></></term>
+      <term><option>-l</> <replaceable class="parameter">locale</></term>
+      <term><option>--locale=</><replaceable class="parameter">locale</></term>
       <listitem>
        <para>
         Specifies the locale to be used in this database.  This is equivalent
@@ -132,7 +132,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--lc-collate=<replaceable class="parameter">locale</replaceable></></term>
+      <term><option>--lc-collate=</><replaceable class="parameter">locale</></term>
       <listitem>
        <para>
         Specifies the LC_COLLATE setting to be used in this database.
@@ -141,7 +141,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--lc-ctype=<replaceable class="parameter">locale</replaceable></></term>
+      <term><option>--lc-ctype=</><replaceable class="parameter">locale</></term>
       <listitem>
        <para>
         Specifies the LC_CTYPE setting to be used in this database.
@@ -150,8 +150,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-O <replaceable class="parameter">owner</replaceable></></term>
-      <term><option>--owner=<replaceable class="parameter">owner</replaceable></></term>
+      <term><option>-O</> <replaceable class="parameter">owner</></term>
+      <term><option>--owner=</><replaceable class="parameter">owner</></term>
       <listitem>
        <para>
         Specifies the database user who will own the new database.
@@ -161,8 +161,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-T <replaceable class="parameter">template</replaceable></></term>
-      <term><option>--template=<replaceable class="parameter">template</replaceable></></term>
+      <term><option>-T</> <replaceable class="parameter">template</></term>
+      <term><option>--template=</><replaceable class="parameter">template</></term>
       <listitem>
        <para>
         Specifies the template database from which to build this
@@ -209,8 +209,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the
@@ -221,8 +221,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP port or the local Unix domain socket file
@@ -232,8 +232,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable class="parameter">username</replaceable></></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></></term>
+      <term><option>-U</> <replaceable class="parameter">username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as.
@@ -278,7 +278,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--maintenance-db=<replaceable class="parameter">dbname</replaceable></></term>
+      <term><option>--maintenance-db=</><replaceable class="parameter">dbname</></term>
       <listitem>
        <para>
          Specifies the name of the database to connect to when creating the
diff --git a/doc/src/sgml/ref/createlang.sgml b/doc/src/sgml/ref/createlang.sgml
index e9c95d3..ef442bc 100644
--- a/doc/src/sgml/ref/createlang.sgml
+++ b/doc/src/sgml/ref/createlang.sgml
@@ -138,8 +138,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the
@@ -151,8 +151,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP port or local Unix domain socket file
@@ -163,8 +163,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable class="parameter">username</replaceable></></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></></term>
+      <term><option>-U</> <replaceable class="parameter">username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as.
diff --git a/doc/src/sgml/ref/createuser.sgml b/doc/src/sgml/ref/createuser.sgml
index 4332008..b36813b 100644
--- a/doc/src/sgml/ref/createuser.sgml
+++ b/doc/src/sgml/ref/createuser.sgml
@@ -77,8 +77,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-c <replaceable class="parameter">number</replaceable></></term>
-      <term><option>--connection-limit=<replaceable class="parameter">number</replaceable></></term>
+      <term><option>-c</> <replaceable class="parameter">number</></term>
+      <term><option>--connection-limit=</><replaceable class="parameter">number</></term>
       <listitem>
        <para>
         Set a maximum number of connections for the new user.
@@ -131,8 +131,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-g <replaceable class="parameter">role</replaceable></></term>
-      <term><option>--role=<replaceable class="parameter">role</replaceable></></term>
+      <term><option>-g</> <replaceable class="parameter">role</></term>
+      <term><option>--role=</><replaceable class="parameter">role</></term>
       <listitem>
        <para>
          Indicates role to which this role will be added immediately as a new
@@ -321,8 +321,8 @@ PostgreSQL documentation
 
    <variablelist>
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the
@@ -334,8 +334,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP port or local Unix domain socket file
@@ -346,8 +346,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable class="parameter">username</replaceable></></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></></term>
+      <term><option>-U</> <replaceable class="parameter">username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as (not the user name to create).
diff --git a/doc/src/sgml/ref/dropdb.sgml b/doc/src/sgml/ref/dropdb.sgml
index 16c49e7..9a167bf 100644
--- a/doc/src/sgml/ref/dropdb.sgml
+++ b/doc/src/sgml/ref/dropdb.sgml
@@ -127,8 +127,8 @@ PostgreSQL documentation
 
    <variablelist>
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the
@@ -140,8 +140,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP port or local Unix domain socket file
@@ -152,8 +152,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable class="parameter">username</replaceable></></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></></term>
+      <term><option>-U</> <replaceable class="parameter">username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as.
@@ -198,7 +198,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--maintenance-db=<replaceable class="parameter">dbname</replaceable></></term>
+      <term><option>--maintenance-db=</><replaceable class="parameter">dbname</></term>
       <listitem>
        <para>
          Specifies the name of the database to connect to in order to drop the
diff --git a/doc/src/sgml/ref/droplang.sgml b/doc/src/sgml/ref/droplang.sgml
index 86f05d6..931ab5a 100644
--- a/doc/src/sgml/ref/droplang.sgml
+++ b/doc/src/sgml/ref/droplang.sgml
@@ -140,8 +140,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the
@@ -153,8 +153,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the Internet TCP/IP port or local Unix domain socket file
@@ -165,8 +165,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable class="parameter">username</replaceable></></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></></term>
+      <term><option>-U</> <replaceable class="parameter">username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as.
diff --git a/doc/src/sgml/ref/dropuser.sgml b/doc/src/sgml/ref/dropuser.sgml
index d7ad61b..2af1f1a 100644
--- a/doc/src/sgml/ref/dropuser.sgml
+++ b/doc/src/sgml/ref/dropuser.sgml
@@ -131,8 +131,8 @@ PostgreSQL documentation
 
    <variablelist>
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the
@@ -144,8 +144,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP port or local Unix domain socket file
@@ -156,8 +156,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable class="parameter">username</replaceable></></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></></term>
+      <term><option>-U</> <replaceable class="parameter">username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as (not the user name to drop).
diff --git a/doc/src/sgml/ref/ecpg-ref.sgml b/doc/src/sgml/ref/ecpg-ref.sgml
index 8bfb47c..7532287 100644
--- a/doc/src/sgml/ref/ecpg-ref.sgml
+++ b/doc/src/sgml/ref/ecpg-ref.sgml
@@ -75,7 +75,7 @@ PostgreSQL documentation
     </varlistentry>
 
     <varlistentry>
-     <term><option>-C <replaceable>mode</replaceable></option></term>
+     <term><option>-C</> <replaceable>mode</></term>
      <listitem>
       <para>
        Set a compatibility mode.  <replaceable>mode</replaceable> can
@@ -86,7 +86,7 @@ PostgreSQL documentation
     </varlistentry>
 
     <varlistentry>
-     <term><option>-D <replaceable>symbol</replaceable></option></term>
+     <term><option>-D</> <replaceable>symbol</></term>
      <listitem>
       <para>
        Define a C preprocessor symbol.
@@ -104,7 +104,7 @@ PostgreSQL documentation
     </varlistentry>
 
     <varlistentry>
-     <term><option>-I <replaceable class="parameter">directory</replaceable></option></term>
+     <term><option>-I</> <replaceable class="parameter">directory</></term>
      <listitem>
       <para>
        Specify an additional include path, used to find files included
@@ -120,7 +120,7 @@ PostgreSQL documentation
     </varlistentry>
 
     <varlistentry>
-     <term><option>-o <replaceable>filename</replaceable></option></term>
+     <term><option>-o</> <replaceable>filename</></term>
      <listitem>
       <para>
        Specifies that <command>ecpg</command> should write all
@@ -130,7 +130,7 @@ PostgreSQL documentation
     </varlistentry>
 
     <varlistentry>
-     <term><option>-r <replaceable>option</replaceable></option></term>
+     <term><option>-r</> <replaceable>option</></term>
      <listitem>
       <para>
        Selects run-time behavior.  <replaceable>Option</replaceable> can be
diff --git a/doc/src/sgml/ref/initdb.sgml b/doc/src/sgml/ref/initdb.sgml
index 1aaa490..9694002 100644
--- a/doc/src/sgml/ref/initdb.sgml
+++ b/doc/src/sgml/ref/initdb.sgml
@@ -116,8 +116,8 @@ PostgreSQL documentation
    <para>
     <variablelist>
      <varlistentry>
-      <term><option>-A <replaceable class="parameter">authmethod</replaceable></option></term>
-      <term><option>--auth=<replaceable class="parameter">authmethod</replaceable></option></term>
+      <term><option>-A</> <replaceable class="parameter">authmethod</></term>
+      <term><option>--auth=</><replaceable class="parameter">authmethod</></term>
       <listitem>
        <para>
         This option specifies the authentication method for local users used
@@ -130,7 +130,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--auth-host=<replaceable class="parameter">authmethod</replaceable></option></term>
+      <term><option>--auth-host=</><replaceable class="parameter">authmethod</></term>
       <listitem>
        <para>
         This option specifies the authentication method for local users via
@@ -141,7 +141,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--auth-local=<replaceable class="parameter">authmethod</replaceable></option></term>
+      <term><option>--auth-local=</><replaceable class="parameter">authmethod</></term>
       <listitem>
        <para>
         This option specifies the authentication method for local users via
@@ -152,8 +152,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-D <replaceable class="parameter">directory</replaceable></option></term>
-      <term><option>--pgdata=<replaceable class="parameter">directory</replaceable></option></term>
+      <term><option>-D</> <replaceable class="parameter">directory</></term>
+      <term><option>--pgdata=</><replaceable class="parameter">directory</></term>
       <listitem>
        <para>
         This option specifies the directory where the database cluster
@@ -168,8 +168,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-E <replaceable class="parameter">encoding</replaceable></option></term>
-      <term><option>--encoding=<replaceable class="parameter">encoding</replaceable></option></term>
+      <term><option>-E</> <replaceable class="parameter">encoding</></term>
+      <term><option>--encoding=</><replaceable class="parameter">encoding</></term>
       <listitem>
        <para>
         Selects the encoding of the template database. This will also
@@ -197,7 +197,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--locale=<replaceable>locale</replaceable></option></term>
+      <term><option>--locale=</><replaceable>locale</></term>
       <listitem>
        <para>
         Sets the default locale for the database cluster.  If this
@@ -209,12 +209,12 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--lc-collate=<replaceable>locale</replaceable></option></term>
-      <term><option>--lc-ctype=<replaceable>locale</replaceable></option></term>
-      <term><option>--lc-messages=<replaceable>locale</replaceable></option></term>
-      <term><option>--lc-monetary=<replaceable>locale</replaceable></option></term>
-      <term><option>--lc-numeric=<replaceable>locale</replaceable></option></term>
-      <term><option>--lc-time=<replaceable>locale</replaceable></option></term>
+      <term><option>--lc-collate=</><replaceable>locale</></term>
+      <term><option>--lc-ctype=</><replaceable>locale</></term>
+      <term><option>--lc-messages=</><replaceable>locale</></term>
+      <term><option>--lc-monetary=</><replaceable>locale</></term>
+      <term><option>--lc-numeric=</><replaceable>locale</></term>
+      <term><option>--lc-time=</><replaceable>locale</></term>
 
       <listitem>
        <para>
@@ -249,7 +249,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--pwfile=<replaceable>filename</></option></term>
+      <term><option>--pwfile=</><replaceable>filename</></term>
       <listitem>
        <para>
         Makes <command>initdb</command> read the database superuser's password
@@ -270,8 +270,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-T <replaceable>CFG</></option></term>
-      <term><option>--text-search-config=<replaceable>CFG</></option></term>
+      <term><option>-T</> <replaceable>CFG</></term>
+      <term><option>--text-search-config=</><replaceable>CFG</></term>
       <listitem>
        <para>
         Sets the default text search configuration.
@@ -281,8 +281,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable class="parameter">username</replaceable></option></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></option></term>
+      <term><option>-U</> <replaceable class="parameter">username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         Selects the user name of the database superuser. This defaults
@@ -310,8 +310,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-X <replaceable class="parameter">directory</replaceable></option></term>
-      <term><option>--waldir=<replaceable class="parameter">directory</replaceable></option></term>
+      <term><option>-X</> <replaceable class="parameter">directory</></term>
+      <term><option>--waldir=</><replaceable class="parameter">directory</></term>
       <listitem>
        <para>
         This option specifies the directory where the transaction log
@@ -342,7 +342,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-L <replaceable class="parameter">directory</replaceable></option></term>
+      <term><option>-L</> <replaceable class="parameter">directory</></term>
       <listitem>
        <para>
         Specifies where <command>initdb</command> should find
diff --git a/doc/src/sgml/ref/pg_basebackup.sgml b/doc/src/sgml/ref/pg_basebackup.sgml
index c9dd62c..da08098 100644
--- a/doc/src/sgml/ref/pg_basebackup.sgml
+++ b/doc/src/sgml/ref/pg_basebackup.sgml
@@ -115,8 +115,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-D <replaceable class="parameter">directory</replaceable></option></term>
-      <term><option>--pgdata=<replaceable class="parameter">directory</replaceable></option></term>
+      <term><option>-D</> <replaceable class="parameter">directory</></term>
+      <term><option>--pgdata=</><replaceable class="parameter">directory</></term>
       <listitem>
        <para>
         Directory to write the output to.
@@ -136,8 +136,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-F <replaceable class="parameter">format</replaceable></option></term>
-      <term><option>--format=<replaceable class="parameter">format</replaceable></option></term>
+      <term><option>-F</> <replaceable class="parameter">format</></term>
+      <term><option>--format=</><replaceable class="parameter">format</></term>
       <listitem>
        <para>
         Selects the format for the output. <replaceable>format</replaceable>
@@ -188,8 +188,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-r <replaceable class="parameter">rate</replaceable></option></term>
-      <term><option>--max-rate=<replaceable class="parameter">rate</replaceable></option></term>
+      <term><option>-r</> <replaceable class="parameter">rate</></term>
+      <term><option>--max-rate=</><replaceable class="parameter">rate</></term>
       <listitem>
        <para>
         The maximum transfer rate of data transferred from the server.  Values are
@@ -227,8 +227,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-S <replaceable>slotname</replaceable></option></term>
-      <term><option>--slot=<replaceable class="parameter">slotname</replaceable></option></term>
+      <term><option>-S</> <replaceable>slotname</></term>
+      <term><option>--slot=</><replaceable class="parameter">slotname</></term>
       <listitem>
        <para>
         This option can only be used together with <literal>-X
@@ -269,8 +269,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-T <replaceable class="parameter">olddir</replaceable>=<replaceable class="parameter">newdir</replaceable></option></term>
-      <term><option>--tablespace-mapping=<replaceable class="parameter">olddir</replaceable>=<replaceable class="parameter">newdir</replaceable></option></term>
+      <term><option>-T</> <replaceable class="parameter">olddir</>=<replaceable class="parameter">newdir</replaceable></term>
+      <term><option>--tablespace-mapping=</><replaceable class="parameter">olddir</>=<replaceable class="parameter">newdir</replaceable></term>
       <listitem>
        <para>
         Relocate the tablespace in directory <replaceable>olddir</replaceable>
@@ -296,7 +296,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--waldir=<replaceable class="parameter">waldir</replaceable></option></term>
+      <term><option>--waldir=</><replaceable class="parameter">waldir</></term>
       <listitem>
        <para>
         Specifies the location for the transaction log directory.
@@ -308,8 +308,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-X <replaceable class="parameter">method</replaceable></option></term>
-      <term><option>--wal-method=<replaceable class="parameter">method</replaceable></option></term>
+      <term><option>-X</> <replaceable class="parameter">method</></term>
+      <term><option>--wal-method=</><replaceable class="parameter">method</></term>
       <listitem>
        <para>
         Includes the required transaction log files (WAL files) in the
@@ -395,8 +395,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-Z <replaceable class="parameter">level</replaceable></option></term>
-      <term><option>--compress=<replaceable class="parameter">level</replaceable></option></term>
+      <term><option>-Z</> <replaceable class="parameter">level</></term>
+      <term><option>--compress=</><replaceable class="parameter">level</></term>
       <listitem>
        <para>
         Enables gzip compression of tar file output, and specifies the
@@ -415,8 +415,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-c <replaceable class="parameter">fast|spread</replaceable></option></term>
-      <term><option>--checkpoint=<replaceable class="parameter">fast|spread</replaceable></option></term>
+      <term><option>-c</> <replaceable class="parameter">fast|spread</></term>
+      <term><option>--checkpoint=</><replaceable class="parameter">fast|spread</></term>
       <listitem>
        <para>
         Sets checkpoint mode to fast or spread (default) (see <xref linkend="backup-lowlevel-base-backup">).
@@ -425,8 +425,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-l <replaceable class="parameter">label</replaceable></option></term>
-      <term><option>--label=<replaceable class="parameter">label</replaceable></option></term>
+      <term><option>-l</> <replaceable class="parameter">label</></term>
+      <term><option>--label=</><replaceable class="parameter">label</></term>
       <listitem>
        <para>
         Sets the label for the backup. If none is specified, a default value of
@@ -510,8 +510,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-d <replaceable class="parameter">connstr</replaceable></option></term>
-      <term><option>--dbname=<replaceable class="parameter">connstr</replaceable></option></term>
+      <term><option>-d</> <replaceable class="parameter">connstr</></term>
+      <term><option>--dbname=</><replaceable class="parameter">connstr</></term>
       <listitem>
        <para>
         Specifies parameters used to connect to the server, as a connection
@@ -527,8 +527,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></option></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></option></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the server is
@@ -541,8 +541,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></option></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></option></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP port or local Unix domain socket file
@@ -554,8 +554,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-s <replaceable class="parameter">interval</replaceable></option></term>
-      <term><option>--status-interval=<replaceable class="parameter">interval</replaceable></option></term>
+      <term><option>-s</> <replaceable class="parameter">interval</></term>
+      <term><option>--status-interval=</><replaceable class="parameter">interval</></term>
       <listitem>
        <para>
         Specifies the number of seconds between status packets sent back to the
@@ -568,8 +568,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable>username</replaceable></option></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></option></term>
+      <term><option>-U</> <replaceable>username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as.
diff --git a/doc/src/sgml/ref/pg_ctl-ref.sgml b/doc/src/sgml/ref/pg_ctl-ref.sgml
index 176dfaf..d3029b2 100644
--- a/doc/src/sgml/ref/pg_ctl-ref.sgml
+++ b/doc/src/sgml/ref/pg_ctl-ref.sgml
@@ -262,8 +262,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-D <replaceable class="parameter">datadir</replaceable></option></term>
-      <term><option>--pgdata=<replaceable class="parameter">datadir</replaceable></option></term>
+      <term><option>-D</> <replaceable class="parameter">datadir</></term>
+      <term><option>--pgdata=</><replaceable class="parameter">datadir</></term>
       <listitem>
        <para>
         Specifies the file system location of the database configuration files.  If
@@ -274,8 +274,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-l <replaceable class="parameter">filename</replaceable></option></term>
-      <term><option>--log=<replaceable class="parameter">filename</replaceable></option></term>
+      <term><option>-l</> <replaceable class="parameter">filename</></term>
+      <term><option>--log=</><replaceable class="parameter">filename</></term>
       <listitem>
        <para>
         Append the server log output to
@@ -287,8 +287,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-m <replaceable class="parameter">mode</replaceable></option></term>
-      <term><option>--mode=<replaceable class="parameter">mode</replaceable></option></term>
+      <term><option>-m</> <replaceable class="parameter">mode</></term>
+      <term><option>--mode=</><replaceable class="parameter">mode</></term>
       <listitem>
        <para>
         Specifies the shutdown mode.  <replaceable>mode</replaceable>
@@ -300,8 +300,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-o <replaceable class="parameter">options</replaceable></option></term>
-      <term><option>--options=<replaceable class="parameter">options</replaceable></option></term>
+      <term><option>-o</> <replaceable class="parameter">options</></term>
+      <term><option>--options=</><replaceable class="parameter">options</></term>
       <listitem>
        <para>
         Specifies options to be passed directly to the
@@ -316,8 +316,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-o <replaceable class="parameter">initdb-options</replaceable></option></term>
-      <term><option>--options=<replaceable class="parameter">initdb-options</replaceable></option></term>
+      <term><option>-o</> <replaceable class="parameter">initdb-options</></term>
+      <term><option>--options=</><replaceable class="parameter">initdb-options</></term>
       <listitem>
        <para>
         Specifies options to be passed directly to the
@@ -331,7 +331,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">path</replaceable></option></term>
+      <term><option>-p</> <replaceable class="parameter">path</></term>
       <listitem>
        <para>
         Specifies the location of the <filename>postgres</filename>
@@ -446,7 +446,7 @@ PostgreSQL documentation
 
    <variablelist>
     <varlistentry>
-     <term><option>-e <replaceable class="parameter">source</replaceable></option></term>
+     <term><option>-e</> <replaceable class="parameter">source</></term>
      <listitem>
       <para>
        Name of the event source for <application>pg_ctl</application> to use
@@ -462,7 +462,7 @@ PostgreSQL documentation
     </varlistentry>
 
     <varlistentry>
-     <term><option>-N <replaceable class="parameter">servicename</replaceable></option></term>
+     <term><option>-N</> <replaceable class="parameter">servicename</></term>
      <listitem>
       <para>
        Name of the system service to register. The name will be used
@@ -472,7 +472,7 @@ PostgreSQL documentation
     </varlistentry>
 
     <varlistentry>
-     <term><option>-P <replaceable class="parameter">password</replaceable></option></term>
+     <term><option>-P</> <replaceable class="parameter">password</></term>
      <listitem>
       <para>
        Password for the user to start the service.
@@ -481,7 +481,7 @@ PostgreSQL documentation
     </varlistentry>
 
     <varlistentry>
-     <term><option>-S <replaceable class="parameter">start-type</replaceable></option></term>
+     <term><option>-S</> <replaceable class="parameter">start-type</></term>
      <listitem>
       <para>
        Start type of the system service to register.  start-type can
@@ -493,7 +493,7 @@ PostgreSQL documentation
     </varlistentry>
 
     <varlistentry>
-     <term><option>-U <replaceable class="parameter">username</replaceable></option></term>
+     <term><option>-U</> <replaceable class="parameter">username</></term>
      <listitem>
       <para>
        User name for the user to start the service. For domain users, use the
diff --git a/doc/src/sgml/ref/pg_dump.sgml b/doc/src/sgml/ref/pg_dump.sgml
index a1e03c4..ea8125f 100644
--- a/doc/src/sgml/ref/pg_dump.sgml
+++ b/doc/src/sgml/ref/pg_dump.sgml
@@ -205,8 +205,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-E <replaceable class="parameter">encoding</replaceable></option></term>
-      <term><option>--encoding=<replaceable class="parameter">encoding</replaceable></option></term>
+      <term><option>-E</> <replaceable class="parameter">encoding</></term>
+      <term><option>--encoding=</><replaceable class="parameter">encoding</></term>
       <listitem>
        <para>
         Create the dump in the specified character set encoding. By default,
@@ -218,8 +218,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-f <replaceable class="parameter">file</replaceable></option></term>
-      <term><option>--file=<replaceable class="parameter">file</replaceable></option></term>
+      <term><option>-f</> <replaceable class="parameter">file</></term>
+      <term><option>--file=</><replaceable class="parameter">file</></term>
       <listitem>
        <para>
         Send output to the specified file. This parameter can be omitted for
@@ -233,8 +233,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-F <replaceable class="parameter">format</replaceable></option></term>
-      <term><option>--format=<replaceable class="parameter">format</replaceable></option></term>
+      <term><option>-F</> <replaceable class="parameter">format</></term>
+      <term><option>--format=</><replaceable class="parameter">format</></term>
       <listitem>
        <para>
         Selects the format of the output.
@@ -305,8 +305,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-j <replaceable class="parameter">njobs</replaceable></></term>
-      <term><option>--jobs=<replaceable class="parameter">njobs</replaceable></></term>
+      <term><option>-j</> <replaceable class="parameter">njobs</></term>
+      <term><option>--jobs=</><replaceable class="parameter">njobs</></term>
       <listitem>
        <para>
         Run the dump in parallel by dumping <replaceable class="parameter">njobs</replaceable>
@@ -360,8 +360,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-n <replaceable class="parameter">schema</replaceable></option></term>
-      <term><option>--schema=<replaceable class="parameter">schema</replaceable></option></term>
+      <term><option>-n</> <replaceable class="parameter">schema</></term>
+      <term><option>--schema=</><replaceable class="parameter">schema</></term>
       <listitem>
        <para>
         Dump only schemas matching <replaceable
@@ -402,8 +402,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-N <replaceable class="parameter">schema</replaceable></option></term>
-      <term><option>--exclude-schema=<replaceable class="parameter">schema</replaceable></option></term>
+      <term><option>-N</> <replaceable class="parameter">schema</></term>
+      <term><option>--exclude-schema=</><replaceable class="parameter">schema</></term>
       <listitem>
        <para>
         Do not dump any schemas matching the <replaceable
@@ -499,8 +499,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-S <replaceable class="parameter">username</replaceable></option></term>
-      <term><option>--superuser=<replaceable class="parameter">username</replaceable></option></term>
+      <term><option>-S</> <replaceable class="parameter">username</></term>
+      <term><option>--superuser=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         Specify the superuser user name to use when disabling triggers.
@@ -512,8 +512,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-t <replaceable class="parameter">table</replaceable></option></term>
-      <term><option>--table=<replaceable class="parameter">table</replaceable></option></term>
+      <term><option>-t</> <replaceable class="parameter">table</></term>
+      <term><option>--table=</><replaceable class="parameter">table</></term>
       <listitem>
        <para>
         Dump only tables with names matching
@@ -564,8 +564,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-T <replaceable class="parameter">table</replaceable></option></term>
-      <term><option>--exclude-table=<replaceable class="parameter">table</replaceable></option></term>
+      <term><option>-T</> <replaceable class="parameter">table</></term>
+      <term><option>--exclude-table=</><replaceable class="parameter">table</></term>
       <listitem>
        <para>
         Do not dump any tables matching the <replaceable
@@ -620,8 +620,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-Z <replaceable class="parameter">0..9</replaceable></option></term>
-      <term><option>--compress=<replaceable class="parameter">0..9</replaceable></option></term>
+      <term><option>-Z</> <replaceable class="parameter">0..9</></term>
+      <term><option>--compress=</><replaceable class="parameter">0..9</></term>
       <listitem>
        <para>
         Specify the compression level to use.  Zero means no compression.
@@ -727,7 +727,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--exclude-table-data=<replaceable class="parameter">table</replaceable></option></term>
+      <term><option>--exclude-table-data=</><replaceable class="parameter">table</></term>
       <listitem>
        <para>
         Do not dump data for any tables matching the <replaceable
@@ -784,7 +784,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--lock-wait-timeout=<replaceable class="parameter">timeout</replaceable></option></term>
+      <term><option>--lock-wait-timeout=</><replaceable class="parameter">timeout</></term>
       <listitem>
        <para>
         Do not wait forever to acquire shared table locks at the beginning of
@@ -878,7 +878,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-       <term><option>--section=<replaceable class="parameter">sectionname</replaceable></option></term>
+       <term><option>--section=</><replaceable class="parameter">sectionname</></term>
        <listitem>
          <para>
           Only dump the named section. The section name can be
@@ -932,7 +932,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-       <term><option>--snapshot=<replaceable class="parameter">snapshotname</replaceable></option></term>
+       <term><option>--snapshot=</><replaceable class="parameter">snapshotname</></term>
        <listitem>
          <para>
           Use the specified synchronized snapshot when making a dump of the
@@ -1008,8 +1008,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-d <replaceable class="parameter">dbname</replaceable></></term>
-      <term><option>--dbname=<replaceable class="parameter">dbname</replaceable></></term>
+      <term><option>-d</> <replaceable class="parameter">dbname</></term>
+      <term><option>--dbname=</><replaceable class="parameter">dbname</></term>
       <listitem>
       <para>
        Specifies the name of the database to connect to. This is
@@ -1028,8 +1028,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></option></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></option></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the server is
@@ -1042,8 +1042,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></option></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></option></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP port or local Unix domain socket file
@@ -1055,8 +1055,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable>username</replaceable></option></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></option></term>
+      <term><option>-U</> <replaceable>username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as.
@@ -1101,7 +1101,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--role=<replaceable class="parameter">rolename</replaceable></option></term>
+      <term><option>--role=</><replaceable class="parameter">rolename</></term>
       <listitem>
        <para>
         Specifies a role name to be used to create the dump.
diff --git a/doc/src/sgml/ref/pg_dumpall.sgml b/doc/src/sgml/ref/pg_dumpall.sgml
index 97168a0..7352e51 100644
--- a/doc/src/sgml/ref/pg_dumpall.sgml
+++ b/doc/src/sgml/ref/pg_dumpall.sgml
@@ -100,8 +100,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-f <replaceable class="parameter">filename</replaceable></option></term>
-      <term><option>--file=<replaceable class="parameter">filename</replaceable></option></term>
+      <term><option>-f</> <replaceable class="parameter">filename</></term>
+      <term><option>--file=</><replaceable class="parameter">filename</></term>
       <listitem>
        <para>
         Send output to the specified file.  If this is omitted, the
@@ -175,8 +175,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-S <replaceable class="parameter">username</replaceable></option></term>
-      <term><option>--superuser=<replaceable class="parameter">username</replaceable></option></term>
+      <term><option>-S</> <replaceable class="parameter">username</></term>
+      <term><option>--superuser=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         Specify the superuser user name to use when disabling triggers.
@@ -317,7 +317,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--lock-wait-timeout=<replaceable class="parameter">timeout</replaceable></option></term>
+      <term><option>--lock-wait-timeout=</><replaceable class="parameter">timeout</></term>
       <listitem>
        <para>
         Do not wait forever to acquire shared table locks at the beginning of
@@ -414,8 +414,8 @@ PostgreSQL documentation
 
    <variablelist>
      <varlistentry>
-      <term><option>-d <replaceable class="parameter">connstr</replaceable></option></term>
-      <term><option>--dbname=<replaceable class="parameter">connstr</replaceable></option></term>
+      <term><option>-d</> <replaceable class="parameter">connstr</></term>
+      <term><option>--dbname=</><replaceable class="parameter">connstr</></term>
       <listitem>
        <para>
         Specifies parameters used to connect to the server, as a connection
@@ -433,8 +433,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-h <replaceable>host</replaceable></option></term>
-      <term><option>--host=<replaceable>host</replaceable></option></term>
+      <term><option>-h</> <replaceable>host</></term>
+      <term><option>--host=</><replaceable>host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the database
@@ -447,8 +447,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-l <replaceable>dbname</replaceable></option></term>
-      <term><option>--database=<replaceable>dbname</replaceable></option></term>
+      <term><option>-l</> <replaceable>dbname</></term>
+      <term><option>--database=</><replaceable>dbname</></term>
       <listitem>
        <para>
          Specifies the name of the database to connect to for dumping global
@@ -460,8 +460,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable>port</replaceable></option></term>
-      <term><option>--port=<replaceable>port</replaceable></option></term>
+      <term><option>-p</> <replaceable>port</></term>
+      <term><option>--port=</><replaceable>port</></term>
       <listitem>
        <para>
         Specifies the TCP port or local Unix domain socket file
@@ -473,8 +473,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable>username</replaceable></option></term>
-      <term><option>--username=<replaceable>username</replaceable></option></term>
+      <term><option>-U</> <replaceable>username</></term>
+      <term><option>--username=</><replaceable>username</></term>
       <listitem>
        <para>
         User name to connect as.
@@ -525,7 +525,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--role=<replaceable class="parameter">rolename</replaceable></option></term>
+      <term><option>--role=</><replaceable class="parameter">rolename</></term>
       <listitem>
        <para>
         Specifies a role name to be used to create the dump.
diff --git a/doc/src/sgml/ref/pg_isready.sgml b/doc/src/sgml/ref/pg_isready.sgml
index 2ee79a0..c34eee0 100644
--- a/doc/src/sgml/ref/pg_isready.sgml
+++ b/doc/src/sgml/ref/pg_isready.sgml
@@ -43,8 +43,8 @@ PostgreSQL documentation
     <variablelist>
 
     <varlistentry>
-      <term><option>-d <replaceable class="parameter">dbname</replaceable></></term>
-      <term><option>--dbname=<replaceable class="parameter">dbname</replaceable></></term>
+      <term><option>-d</> <replaceable class="parameter">dbname</></term>
+      <term><option>--dbname=</><replaceable class="parameter">dbname</></term>
       <listitem>
       <para>
        Specifies the name of the database to connect to.
@@ -61,8 +61,8 @@ PostgreSQL documentation
     </varlistentry>
 
      <varlistentry>
-       <term><option>-h <replaceable class="parameter">hostname</replaceable></></term>
-       <term><option>--host=<replaceable class="parameter">hostname</replaceable></></term>
+       <term><option>-h</> <replaceable class="parameter">hostname</></term>
+       <term><option>--host=</><replaceable class="parameter">hostname</></term>
        <listitem>
        <para>
        Specifies the host name of the machine on which the
@@ -74,8 +74,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-       <term><option>-p <replaceable class="parameter">port</replaceable></></term>
-       <term><option>--port=<replaceable class="parameter">port</replaceable></></term>
+       <term><option>-p</> <replaceable class="parameter">port</></term>
+       <term><option>--port=</><replaceable class="parameter">port</></term>
        <listitem>
        <para>
        Specifies the TCP port or the local Unix-domain
@@ -98,8 +98,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-       <term><option>-t <replaceable class="parameter">seconds</replaceable></></term>
-       <term><option>--timeout=<replaceable class="parameter">seconds</replaceable></></term>
+       <term><option>-t</> <replaceable class="parameter">seconds</></term>
+       <term><option>--timeout=</><replaceable class="parameter">seconds</></term>
        <listitem>
        <para>
         The maximum number of seconds to wait when attempting connection before
@@ -110,8 +110,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-       <term><option>-U <replaceable class="parameter">username</replaceable></></term>
-       <term><option>--username=<replaceable class="parameter">username</replaceable></></term>
+       <term><option>-U</> <replaceable class="parameter">username</></term>
+       <term><option>--username=</><replaceable class="parameter">username</></term>
        <listitem>
        <para>
        Connect to the database as the user <replaceable
diff --git a/doc/src/sgml/ref/pg_receivewal.sgml b/doc/src/sgml/ref/pg_receivewal.sgml
index 0e6b636..a7bd63c 100644
--- a/doc/src/sgml/ref/pg_receivewal.sgml
+++ b/doc/src/sgml/ref/pg_receivewal.sgml
@@ -80,8 +80,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-D <replaceable class="parameter">directory</replaceable></option></term>
-      <term><option>--directory=<replaceable class="parameter">directory</replaceable></option></term>
+      <term><option>-D</> <replaceable class="parameter">directory</></term>
+      <term><option>--directory=</><replaceable class="parameter">directory</></term>
       <listitem>
        <para>
         Directory to write the output to.
@@ -114,8 +114,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-s <replaceable class="parameter">interval</replaceable></option></term>
-      <term><option>--status-interval=<replaceable class="parameter">interval</replaceable></option></term>
+      <term><option>-s</> <replaceable class="parameter">interval</></term>
+      <term><option>--status-interval=</><replaceable class="parameter">interval</></term>
       <listitem>
        <para>
         Specifies the number of seconds between status packets sent back to the
@@ -128,8 +128,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-S <replaceable>slotname</replaceable></option></term>
-      <term><option>--slot=<replaceable class="parameter">slotname</replaceable></option></term>
+      <term><option>-S</> <replaceable>slotname</></term>
+      <term><option>--slot=</><replaceable class="parameter">slotname</></term>
       <listitem>
         <para>
          Require <application>pg_receivewal</application> to use an existing
@@ -182,8 +182,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-Z <replaceable class="parameter">level</replaceable></option></term>
-      <term><option>--compress=<replaceable class="parameter">level</replaceable></option></term>
+      <term><option>-Z</> <replaceable class="parameter">level</></term>
+      <term><option>--compress=</><replaceable class="parameter">level</></term>
       <listitem>
        <para>
         Enables gzip compression of transaction logs, and specifies the
@@ -200,8 +200,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-d <replaceable class="parameter">connstr</replaceable></option></term>
-      <term><option>--dbname=<replaceable class="parameter">connstr</replaceable></option></term>
+      <term><option>-d</> <replaceable class="parameter">connstr</></term>
+      <term><option>--dbname=</><replaceable class="parameter">connstr</></term>
       <listitem>
        <para>
         Specifies parameters used to connect to the server, as a connection
@@ -217,8 +217,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></option></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></option></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the server is
@@ -231,8 +231,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></option></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></option></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP port or local Unix domain socket file
@@ -244,8 +244,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable>username</replaceable></option></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></option></term>
+      <term><option>-U</> <replaceable>username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as.
diff --git a/doc/src/sgml/ref/pg_recvlogical.sgml b/doc/src/sgml/ref/pg_recvlogical.sgml
index eaea94d..5d2a61a 100644
--- a/doc/src/sgml/ref/pg_recvlogical.sgml
+++ b/doc/src/sgml/ref/pg_recvlogical.sgml
@@ -114,8 +114,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-f <replaceable>filename</replaceable></option></term>
-      <term><option>--file=<replaceable>filename</replaceable></option></term>
+      <term><option>-f</> <replaceable>filename</></term>
+      <term><option>--file=</><replaceable>filename</></term>
       <listitem>
        <para>
         Write received and decoded transaction data into this
@@ -125,8 +125,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-F <replaceable>interval_seconds</replaceable></option></term>
-      <term><option>--fsync-interval=<replaceable>interval_seconds</replaceable></option></term>
+      <term><option>-F</> <replaceable>interval_seconds</></term>
+      <term><option>--fsync-interval=</><replaceable>interval_seconds</></term>
       <listitem>
        <para>
         Specifies how often <application>pg_recvlogical</application> should
@@ -150,8 +150,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-I <replaceable>lsn</replaceable></option></term>
-      <term><option>--startpos=<replaceable>lsn</replaceable></option></term>
+      <term><option>-I</> <replaceable>lsn</></term>
+      <term><option>--startpos=</><replaceable>lsn</></term>
       <listitem>
        <para>
         In <option>--start</option> mode, start replication from the given
@@ -163,8 +163,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-E <replaceable>lsn</replaceable></option></term>
-      <term><option>--endpos=<replaceable>lsn</replaceable></option></term>
+      <term><option>-E</> <replaceable>lsn</></term>
+      <term><option>--endpos=</><replaceable>lsn</></term>
       <listitem>
        <para>
         In <option>--start</option> mode, automatically stop replication
@@ -209,8 +209,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-o <replaceable>name</replaceable>[=<replaceable>value</replaceable>]</option></term>
-      <term><option>--option=<replaceable>name</replaceable>[=<replaceable>value</replaceable>]</option></term>
+      <term><option>-o</> <replaceable>name</>[<literal>=</><replaceable>value</>]</term>
+      <term><option>--option=</><replaceable>name</>[<literal>=</><replaceable>value</>]</term>
       <listitem>
        <para>
         Pass the option <replaceable>name</replaceable> to the output plugin with,
@@ -221,8 +221,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-P <replaceable>plugin</replaceable></option></term>
-      <term><option>--plugin=<replaceable>plugin</replaceable></option></term>
+      <term><option>-P</> <replaceable>plugin</></term>
+      <term><option>--plugin=</><replaceable>plugin</></term>
       <listitem>
        <para>
         When creating a slot, use the specified logical decoding output
@@ -233,8 +233,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-s <replaceable>interval_seconds</replaceable></option></term>
-      <term><option>--status-interval=<replaceable>interval_seconds</replaceable></option></term>
+      <term><option>-s</> <replaceable>interval_seconds</></term>
+      <term><option>--status-interval=</><replaceable>interval_seconds</></term>
       <listitem>
        <para>
         This option has the same effect as the option of the same name
@@ -244,8 +244,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-S <replaceable>slot_name</replaceable></option></term>
-      <term><option>--slot=<replaceable>slot_name</replaceable></option></term>
+      <term><option>-S</> <replaceable>slot_name</></term>
+      <term><option>--slot=</><replaceable>slot_name</></term>
       <listitem>
        <para>
         In <option>--start</option> mode, use the existing logical replication slot named
@@ -273,8 +273,8 @@ PostgreSQL documentation
 
     <variablelist>
       <varlistentry>
-       <term><option>-d <replaceable>database</replaceable></option></term>
-       <term><option>--dbname=<replaceable>database</replaceable></option></term>
+       <term><option>-d</> <replaceable>database</></term>
+       <term><option>--dbname=</><replaceable>database</></term>
        <listitem>
         <para>
          The database to connect to.  See the description of the actions for
@@ -286,8 +286,8 @@ PostgreSQL documentation
       </varlistentry>
 
       <varlistentry>
-       <term><option>-h <replaceable>hostname-or-ip</replaceable></option></term>
-       <term><option>--host=<replaceable>hostname-or-ip</replaceable></option></term>
+       <term><option>-h</> <replaceable>hostname-or-ip</></term>
+       <term><option>--host=</><replaceable>hostname-or-ip</></term>
        <listitem>
         <para>
          Specifies the host name of the machine on which the server is
@@ -300,8 +300,8 @@ PostgreSQL documentation
       </varlistentry>
 
       <varlistentry>
-       <term><option>-p <replaceable>port</replaceable></option></term>
-       <term><option>--port=<replaceable>port</replaceable></option></term>
+       <term><option>-p</> <replaceable>port</></term>
+       <term><option>--port=</><replaceable>port</></term>
        <listitem>
         <para>
          Specifies the TCP port or local Unix domain socket file
@@ -313,8 +313,8 @@ PostgreSQL documentation
       </varlistentry>
 
       <varlistentry>
-       <term><option>-U <replaceable>user</replaceable></option></term>
-       <term><option>--username=<replaceable>user</replaceable></option></term>
+       <term><option>-U</> <replaceable>user</></term>
+       <term><option>--username=</><replaceable>user</></term>
        <listitem>
         <para>
          User name to connect as.  Defaults to current operating system user
diff --git a/doc/src/sgml/ref/pg_restore.sgml b/doc/src/sgml/ref/pg_restore.sgml
index 44f0515..ae8c817 100644
--- a/doc/src/sgml/ref/pg_restore.sgml
+++ b/doc/src/sgml/ref/pg_restore.sgml
@@ -136,8 +136,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-d <replaceable class="parameter">dbname</replaceable></option></term>
-      <term><option>--dbname=<replaceable class="parameter">dbname</replaceable></option></term>
+      <term><option>-d</> <replaceable class="parameter">dbname</></term>
+      <term><option>--dbname=</><replaceable class="parameter">dbname</></term>
       <listitem>
        <para>
         Connect to database <replaceable
@@ -160,8 +160,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-f <replaceable>filename</replaceable></option></term>
-      <term><option>--file=<replaceable>filename</replaceable></option></term>
+      <term><option>-f</> <replaceable>filename</></term>
+      <term><option>--file=</><replaceable>filename</></term>
       <listitem>
        <para>
         Specify output file for generated script, or for the listing
@@ -172,8 +172,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-F <replaceable class="parameter">format</replaceable></option></term>
-      <term><option>--format=<replaceable class="parameter">format</replaceable></option></term>
+      <term><option>-F</> <replaceable class="parameter">format</></term>
+      <term><option>--format=</><replaceable class="parameter">format</></term>
       <listitem>
        <para>
         Specify format of the archive.  It is not necessary to specify
@@ -217,8 +217,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-I <replaceable class="parameter">index</replaceable></option></term>
-      <term><option>--index=<replaceable class="parameter">index</replaceable></option></term>
+      <term><option>-I</> <replaceable class="parameter">index</></term>
+      <term><option>--index=</><replaceable class="parameter">index</></term>
       <listitem>
        <para>
         Restore definition of named index only.  Multiple indexes
@@ -228,8 +228,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-j <replaceable class="parameter">number-of-jobs</replaceable></option></term>
-      <term><option>--jobs=<replaceable class="parameter">number-of-jobs</replaceable></option></term>
+      <term><option>-j</> <replaceable class="parameter">number-of-jobs</></term>
+      <term><option>--jobs=</><replaceable class="parameter">number-of-jobs</></term>
       <listitem>
        <para>
         Run the most time-consuming parts
@@ -282,8 +282,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-L <replaceable class="parameter">list-file</replaceable></option></term>
-      <term><option>--use-list=<replaceable class="parameter">list-file</replaceable></option></term>
+      <term><option>-L</> <replaceable class="parameter">list-file</></term>
+      <term><option>--use-list=</><replaceable class="parameter">list-file</></term>
       <listitem>
        <para>
         Restore only those archive elements that are listed in <replaceable
@@ -302,8 +302,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-n <replaceable class="parameter">schema</replaceable></option></term>
-      <term><option>--schema=<replaceable class="parameter">schema</replaceable></option></term>
+      <term><option>-n</> <replaceable class="parameter">schema</></term>
+      <term><option>--schema=</><replaceable class="parameter">schema</></term>
       <listitem>
        <para>
         Restore only objects that are in the named schema.  Multiple schemas
@@ -315,8 +315,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-N <replaceable class="parameter">schema</replaceable></option></term>
-      <term><option>--exclude-schema=<replaceable class="parameter">schema</replaceable></option></term>
+      <term><option>-N</> <replaceable class="parameter">schema</></term>
+      <term><option>--exclude-schema=</><replaceable class="parameter">schema</></term>
       <listitem>
        <para>
         Do not restore objects that are in the named schema.  Multiple schemas
@@ -351,8 +351,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-P <replaceable class="parameter">function-name(argtype [, ...])</replaceable></option></term>
-      <term><option>--function=<replaceable class="parameter">function-name(argtype [, ...])</replaceable></option></term>
+      <term><option>-P</> <replaceable class="parameter">function-name(argtype [, ...])</></term>
+      <term><option>--function=</><replaceable class="parameter">function-name(argtype [, ...])</></term>
       <listitem>
        <para>
         Restore the named function only.  Be careful to spell the function
@@ -396,8 +396,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-S <replaceable class="parameter">username</replaceable></option></term>
-      <term><option>--superuser=<replaceable class="parameter">username</replaceable></option></term>
+      <term><option>-S</> <replaceable class="parameter">username</></term>
+      <term><option>--superuser=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         Specify the superuser user name to use when disabling triggers.
@@ -407,8 +407,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-t <replaceable class="parameter">table</replaceable></option></term>
-      <term><option>--table=<replaceable class="parameter">table</replaceable></option></term>
+      <term><option>-t</> <replaceable class="parameter">table</></term>
+      <term><option>--table=</><replaceable class="parameter">table</></term>
       <listitem>
        <para>
         Restore definition and/or data of only the named table.
@@ -448,8 +448,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-T <replaceable class="parameter">trigger</replaceable></option></term>
-      <term><option>--trigger=<replaceable class="parameter">trigger</replaceable></option></term>
+      <term><option>-T</> <replaceable class="parameter">trigger</></term>
+      <term><option>--trigger=</><replaceable class="parameter">trigger</></term>
       <listitem>
        <para>
         Restore named trigger only.  Multiple triggers may be specified with
@@ -603,7 +603,7 @@
      </varlistentry>
 
      <varlistentry>
-       <term><option>--section=<replaceable class="parameter">sectionname</replaceable></option></term>
+       <term><option>--section=</><replaceable class="parameter">sectionname</></term>
        <listitem>
          <para>
           Only restore the named section. The section name can be
@@ -666,8 +666,8 @@
 
     <variablelist>
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></option></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></option></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the server is
@@ -680,8 +680,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></option></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></option></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP port or local Unix domain socket file
@@ -693,8 +693,8 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable>username</replaceable></option></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></option></term>
+      <term><option>-U</> <replaceable>username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as.
@@ -739,7 +739,7 @@
      </varlistentry>
 
      <varlistentry>
-      <term><option>--role=<replaceable class="parameter">rolename</replaceable></option></term>
+      <term><option>--role=</><replaceable class="parameter">rolename</></term>
       <listitem>
        <para>
         Specifies a role name to be used to perform the restore.
diff --git a/doc/src/sgml/ref/pg_rewind.sgml b/doc/src/sgml/ref/pg_rewind.sgml
index 371c4a4..61e9677 100644
--- a/doc/src/sgml/ref/pg_rewind.sgml
+++ b/doc/src/sgml/ref/pg_rewind.sgml
@@ -30,8 +30,8 @@ PostgreSQL documentation
     </group>
     <replaceable> directory</replaceable>
     <group choice="req">
-     <arg choice="plain"><option>--source-pgdata=<replaceable>directory</replaceable></option></arg>
-     <arg choice="plain"><option>--source-server=<replaceable>connstr</replaceable></option></arg>
+     <arg choice="plain"><option>--source-pgdata=</><replaceable>directory</></arg>
+     <arg choice="plain"><option>--source-server=</><replaceable>connstr</></arg>
     </group>
    </group>
   </cmdsynopsis>
@@ -106,8 +106,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-D <replaceable class="parameter">directory</replaceable></option></term>
-      <term><option>--target-pgdata=<replaceable class="parameter">directory</replaceable></option></term>
+      <term><option>-D</> <replaceable class="parameter">directory</></term>
+      <term><option>--target-pgdata=</><replaceable class="parameter">directory</></term>
       <listitem>
        <para>
         This option specifies the target data directory that is synchronized
@@ -118,7 +118,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--source-pgdata=<replaceable class="parameter">directory</replaceable></option></term>
+      <term><option>--source-pgdata=</><replaceable class="parameter">directory</></term>
       <listitem>
        <para>
         Specifies the file system path to the data directory of the source
@@ -129,7 +129,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--source-server=<replaceable class="parameter">connstr</replaceable></option></term>
+      <term><option>--source-server=</><replaceable class="parameter">connstr</></term>
       <listitem>
        <para>
         Specifies a libpq connection string to connect to the source
diff --git a/doc/src/sgml/ref/pg_waldump.sgml b/doc/src/sgml/ref/pg_waldump.sgml
index 4c92eee..178af8b 100644
--- a/doc/src/sgml/ref/pg_waldump.sgml
+++ b/doc/src/sgml/ref/pg_waldump.sgml
@@ -81,8 +81,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-e <replaceable>end</replaceable></option></term>
-      <term><option>--end=<replaceable>end</replaceable></option></term>
+      <term><option>-e</> <replaceable>end</></term>
+      <term><option>--end=</><replaceable>end</></term>
       <listitem>
        <para>
         Stop reading at the specified log position, instead of reading to the
@@ -103,8 +103,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-n <replaceable>limit</replaceable></option></term>
-      <term><option>--limit=<replaceable>limit</replaceable></option></term>
+      <term><option>-n</> <replaceable>limit</></term>
+      <term><option>--limit=</><replaceable>limit</></term>
       <listitem>
        <para>
         Display the specified number of records, then stop.
@@ -113,8 +113,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable>path</replaceable></option></term>
-      <term><option>--path=<replaceable>path</replaceable></option></term>
+      <term><option>-p</> <replaceable>path</></term>
+      <term><option>--path=</><replaceable>path</></term>
       <listitem>
        <para>
         Specifies a directory to search for log segment files or a
@@ -128,8 +128,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-r <replaceable>rmgr</replaceable></option></term>
-      <term><option>--rmgr=<replaceable>rmgr</replaceable></option></term>
+      <term><option>-r</> <replaceable>rmgr</></term>
+      <term><option>--rmgr=</><replaceable>rmgr</></term>
       <listitem>
        <para>
         Only display records generated by the specified resource manager.
@@ -140,8 +140,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-s <replaceable>start</replaceable></option></term>
-      <term><option>--start=<replaceable>start</replaceable></option></term>
+      <term><option>-s</> <replaceable>start</></term>
+      <term><option>--start=</><replaceable>start</></term>
       <listitem>
        <para>
         Log position at which to start reading. The default is to start reading
@@ -151,8 +151,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-t <replaceable>timeline</replaceable></option></term>
-      <term><option>--timeline=<replaceable>timeline</replaceable></option></term>
+      <term><option>-t</> <replaceable>timeline</></term>
+      <term><option>--timeline=</><replaceable>timeline</></term>
       <listitem>
        <para>
         Timeline from which to read log records. The default is to use the
@@ -173,8 +173,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-x <replaceable>xid</replaceable></option></term>
-      <term><option>--xid=<replaceable>xid</replaceable></option></term>
+      <term><option>-x</> <replaceable>xid</></term>
+      <term><option>--xid=</><replaceable>xid</></term>
       <listitem>
        <para>
         Only display records marked with the given transaction ID.
diff --git a/doc/src/sgml/ref/pgbench.sgml b/doc/src/sgml/ref/pgbench.sgml
index 1eee8dc..ef26283 100644
--- a/doc/src/sgml/ref/pgbench.sgml
+++ b/doc/src/sgml/ref/pgbench.sgml
@@ -220,7 +220,7 @@ pgbench <optional> <replaceable>options</> </optional> <replaceable>dbname</>
      </varlistentry>
 
      <varlistentry>
-      <term><option>--index-tablespace=<replaceable>index_tablespace</replaceable></option></term>
+      <term><option>--index-tablespace=</><replaceable>index_tablespace</replaceable></term>
       <listitem>
        <para>
         Create indexes in the specified tablespace, rather than the default
@@ -230,7 +230,7 @@ pgbench <optional> <replaceable>options</> </optional> <replaceable>dbname</>
      </varlistentry>
 
      <varlistentry>
-      <term><option>--tablespace=<replaceable>tablespace</replaceable></option></term>
+      <term><option>--tablespace=</><replaceable>tablespace</replaceable></term>
       <listitem>
        <para>
         Create tables in the specified tablespace, rather than the default
@@ -262,8 +262,8 @@ pgbench <optional> <replaceable>options</> </optional> <replaceable>dbname</>
 
     <variablelist>
      <varlistentry>
-      <term><option>-b</> <replaceable>scriptname[@weight]</></term>
-      <term><option>--builtin</>=<replaceable>scriptname[@weight]</></term>
+      <term><option>-b</> <replaceable>scriptname</>[<literal>@</><replaceable>weight</>]</term>
+      <term><option>--builtin=</><replaceable>scriptname</>[<literal>@</><replaceable>weight</>]</term>
       <listitem>
        <para>
         Add the specified built-in script to the list of executed scripts.
@@ -569,7 +569,7 @@ pgbench <optional> <replaceable>options</> </optional> <replaceable>dbname</>
      </varlistentry>
 
      <varlistentry>
-      <term><option>--aggregate-interval=<replaceable>seconds</></option></term>
+      <term><option>--aggregate-interval=</><replaceable>seconds</></term>
       <listitem>
        <para>
         Length of aggregation interval (in seconds).  May be used only
@@ -593,7 +593,7 @@ pgbench <optional> <replaceable>options</> </optional> <replaceable>dbname</>
      </varlistentry>
 
      <varlistentry>
-      <term><option>--sampling-rate=<replaceable>rate</></option></term>
+      <term><option>--sampling-rate=</><replaceable>rate</></term>
       <listitem>
        <para>
         Sampling rate, used when writing data into the log, to reduce the
@@ -611,7 +611,7 @@ pgbench <optional> <replaceable>options</> </optional> <replaceable>dbname</>
      </varlistentry>
 
      <varlistentry>
-      <term><option>--log-prefix=<replaceable>prefix</></option></term>
+      <term><option>--log-prefix=</><replaceable>prefix</></term>
       <listitem>
        <para>
         Set the filename prefix for the transaction log files created by
diff --git a/doc/src/sgml/ref/pgtesttiming.sgml b/doc/src/sgml/ref/pgtesttiming.sgml
index e3539cf..2dfeff1 100644
--- a/doc/src/sgml/ref/pgtesttiming.sgml
+++ b/doc/src/sgml/ref/pgtesttiming.sgml
@@ -44,8 +44,8 @@
     <variablelist>
 
      <varlistentry>
-      <term><option>-d <replaceable class="parameter">duration</replaceable></option></term>
-      <term><option>--duration=<replaceable class="parameter">duration</replaceable></option></term>
+      <term><option>-d</> <replaceable class="parameter">duration</></term>
+      <term><option>--duration=</><replaceable class="parameter">duration</></term>
       <listitem>
        <para>
         Specifies the test duration, in seconds. Longer durations
diff --git a/doc/src/sgml/ref/postgres-ref.sgml b/doc/src/sgml/ref/postgres-ref.sgml
index fc11aa1..3c7172e 100644
--- a/doc/src/sgml/ref/postgres-ref.sgml
+++ b/doc/src/sgml/ref/postgres-ref.sgml
@@ -102,7 +102,7 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-B <replaceable class="parameter">nbuffers</replaceable></option></term>
+      <term><option>-B</> <replaceable class="parameter">nbuffers</></term>
       <listitem>
        <para>
         Sets the number of shared buffers for use by the server
@@ -115,7 +115,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-c <replaceable>name</replaceable>=<replaceable>value</replaceable></option></term>
+      <term><option>-c</> <replaceable>name</>=<replaceable>value</replaceable></term>
       <listitem>
        <para>
         Sets a named run-time parameter. The configuration parameters
@@ -129,7 +129,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-C <replaceable>name</replaceable></option></term>
+      <term><option>-C</> <replaceable>name</></term>
       <listitem>
        <para>
         Prints the value of the named run-time parameter, and exits.
@@ -150,7 +150,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-d <replaceable>debug-level</replaceable></option></term>
+      <term><option>-d</> <replaceable>debug-level</></term>
       <listitem>
        <para>
         Sets the debug level.  The higher this value is set, the more
@@ -164,7 +164,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-D <replaceable class="parameter">datadir</replaceable></option></term>
+      <term><option>-D</> <replaceable class="parameter">datadir</></term>
       <listitem>
        <para>
         Specifies the file system location of the database
@@ -200,7 +200,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">hostname</replaceable></option></term>
+      <term><option>-h</> <replaceable class="parameter">hostname</></term>
       <listitem>
        <para>
         Specifies the IP host name or address on which
@@ -237,7 +237,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-k <replaceable class="parameter">directory</replaceable></option></term>
+      <term><option>-k</> <replaceable class="parameter">directory</></term>
       <listitem>
        <para>
         Specifies the directory of the Unix-domain socket on which
@@ -268,7 +268,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-N <replaceable class="parameter">max-connections</replaceable></option></term>
+      <term><option>-N</> <replaceable class="parameter">max-connections</></term>
       <listitem>
        <para>
         Sets the maximum number of client connections that this
@@ -281,7 +281,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-o <replaceable class="parameter">extra-options</replaceable></option></term>
+      <term><option>-o</> <replaceable class="parameter">extra-options</></term>
       <listitem>
        <para>
         The command-line-style arguments specified in <replaceable
@@ -307,7 +307,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></option></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP/IP port or local Unix domain socket file
@@ -357,7 +357,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--<replaceable>name</replaceable>=<replaceable>value</replaceable></option></term>
+      <term><option>--</><replaceable>name</>=<replaceable>value</replaceable></term>
       <listitem>
        <para>
         Sets a named run-time parameter; a shorter form of
diff --git a/doc/src/sgml/ref/psql-ref.sgml b/doc/src/sgml/ref/psql-ref.sgml
index ae58708..7fa6fb5 100644
--- a/doc/src/sgml/ref/psql-ref.sgml
+++ b/doc/src/sgml/ref/psql-ref.sgml
@@ -86,8 +86,8 @@ PostgreSQL documentation
     </varlistentry>
 
     <varlistentry>
-      <term><option>-c <replaceable class="parameter">command</replaceable></></term>
-      <term><option>--command=<replaceable class="parameter">command</replaceable></></term>
+      <term><option>-c</> <replaceable class="parameter">command</></term>
+      <term><option>--command=</><replaceable class="parameter">command</></term>
       <listitem>
       <para>
        Specifies that <application>psql</application> is to execute the given
@@ -149,8 +149,8 @@ EOF
     </varlistentry>
 
     <varlistentry>
-      <term><option>-d <replaceable class="parameter">dbname</replaceable></></term>
-      <term><option>--dbname=<replaceable class="parameter">dbname</replaceable></></term>
+      <term><option>-d</> <replaceable class="parameter">dbname</></term>
+      <term><option>--dbname=</><replaceable class="parameter">dbname</></term>
       <listitem>
       <para>
        Specifies the name of the database to connect to. This is
@@ -196,8 +196,8 @@ EOF
     </varlistentry>
 
     <varlistentry>
-      <term><option>-f <replaceable class="parameter">filename</replaceable></></term>
-      <term><option>--file=<replaceable class="parameter">filename</replaceable></></term>
+      <term><option>-f</> <replaceable class="parameter">filename</></term>
+      <term><option>--file=</><replaceable class="parameter">filename</></term>
       <listitem>
       <para>
        Read commands from the
@@ -238,8 +238,8 @@ EOF
     </varlistentry>
 
     <varlistentry>
-      <term><option>-F <replaceable class="parameter">separator</replaceable></></term>
-      <term><option>--field-separator=<replaceable class="parameter">separator</replaceable></></term>
+      <term><option>-F</> <replaceable class="parameter">separator</></term>
+      <term><option>--field-separator=</><replaceable class="parameter">separator</></term>
       <listitem>
       <para>
       Use <replaceable class="parameter">separator</replaceable> as the
@@ -250,8 +250,8 @@ EOF
     </varlistentry>
 
     <varlistentry>
-      <term><option>-h <replaceable class="parameter">hostname</replaceable></></term>
-      <term><option>--host=<replaceable class="parameter">hostname</replaceable></></term>
+      <term><option>-h</> <replaceable class="parameter">hostname</></term>
+      <term><option>--host=</><replaceable class="parameter">hostname</></term>
       <listitem>
       <para>
       Specifies the host name of the machine on which the
@@ -287,8 +287,8 @@ EOF
     </varlistentry>
 
     <varlistentry>
-      <term><option>-L <replaceable class="parameter">filename</replaceable></></term>
-      <term><option>--log-file=<replaceable class="parameter">filename</replaceable></></term>
+      <term><option>-L</> <replaceable class="parameter">filename</></term>
+      <term><option>--log-file=</><replaceable class="parameter">filename</></term>
       <listitem>
       <para>
        Write all query output into file <replaceable
@@ -311,8 +311,8 @@ EOF
     </varlistentry>
 
     <varlistentry>
-      <term><option>-o <replaceable class="parameter">filename</replaceable></></term>
-      <term><option>--output=<replaceable class="parameter">filename</replaceable></></term>
+      <term><option>-o</> <replaceable class="parameter">filename</></term>
+      <term><option>--output=</><replaceable class="parameter">filename</></term>
       <listitem>
       <para>
       Put all query output into file <replaceable
@@ -323,8 +323,8 @@ EOF
     </varlistentry>
 
     <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
       <para>
       Specifies the TCP port or the local Unix-domain
@@ -337,8 +337,8 @@ EOF
     </varlistentry>
 
     <varlistentry>
-      <term><option>-P <replaceable class="parameter">assignment</replaceable></></term>
-      <term><option>--pset=<replaceable class="parameter">assignment</replaceable></></term>
+      <term><option>-P</> <replaceable class="parameter">assignment</></term>
+      <term><option>--pset=</><replaceable class="parameter">assignment</></term>
       <listitem>
       <para>
       Specifies printing options, in the style of
@@ -366,8 +366,8 @@ EOF
     </varlistentry>
 
     <varlistentry>
-      <term><option>-R <replaceable class="parameter">separator</replaceable></></term>
-      <term><option>--record-separator=<replaceable class="parameter">separator</replaceable></></term>
+      <term><option>-R</> <replaceable class="parameter">separator</></term>
+      <term><option>--record-separator=</><replaceable class="parameter">separator</></term>
       <listitem>
       <para>
       Use <replaceable class="parameter">separator</replaceable> as the
@@ -421,8 +421,8 @@ EOF
     </varlistentry>
 
     <varlistentry>
-      <term><option>-T <replaceable class="parameter">table_options</replaceable></></term>
-      <term><option>--table-attr=<replaceable class="parameter">table_options</replaceable></></term>
+      <term><option>-T</> <replaceable class="parameter">table_options</></term>
+      <term><option>--table-attr=</><replaceable class="parameter">table_options</></term>
       <listitem>
       <para>
       Specifies options to be placed within the
@@ -433,8 +433,8 @@ EOF
     </varlistentry>
 
     <varlistentry>
-      <term><option>-U <replaceable class="parameter">username</replaceable></></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></></term>
+      <term><option>-U</> <replaceable class="parameter">username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
       <para>
       Connect to the database as the user <replaceable
@@ -445,9 +445,9 @@ EOF
     </varlistentry>
 
     <varlistentry>
-      <term><option>-v <replaceable class="parameter">assignment</replaceable></></term>
-      <term><option>--set=<replaceable class="parameter">assignment</replaceable></></term>
-      <term><option>--variable=<replaceable class="parameter">assignment</replaceable></></term>
+      <term><option>-v</> <replaceable class="parameter">assignment</></term>
+      <term><option>--set=</><replaceable class="parameter">assignment</></term>
+      <term><option>--variable=</><replaceable class="parameter">assignment</></term>
       <listitem>
       <para>
       Perform a variable assignment, like the <command>\set</command>
@@ -588,7 +588,7 @@ EOF
 
     <varlistentry>
       <term><option>-?</></term>
-      <term><option>--help[=<replaceable class="parameter">topic</>]</option></term>
+      <term><option>--help</>[<literal>=</><replaceable class="parameter">topic</>]</term>
       <listitem>
       <para>
       Show help about <application>psql</application> and exit. The optional
diff --git a/doc/src/sgml/ref/reindexdb.sgml b/doc/src/sgml/ref/reindexdb.sgml
index e4721d8..5259cfe 100644
--- a/doc/src/sgml/ref/reindexdb.sgml
+++ b/doc/src/sgml/ref/reindexdb.sgml
@@ -145,8 +145,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-i <replaceable class="parameter">index</replaceable></></term>
-      <term><option>--index=<replaceable class="parameter">index</replaceable></></term>
+      <term><option>-i</> <replaceable class="parameter">index</></term>
+      <term><option>--index=</><replaceable class="parameter">index</></term>
       <listitem>
        <para>
         Recreate <replaceable class="parameter">index</replaceable> only.
@@ -177,8 +177,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-S <replaceable class="parameter">schema</replaceable></></term>
-      <term><option>--schema=<replaceable class="parameter">schema</replaceable></></term>
+      <term><option>-S</> <replaceable class="parameter">schema</></term>
+      <term><option>--schema=</><replaceable class="parameter">schema</></term>
       <listitem>
        <para>
         Reindex <replaceable class="parameter">schema</replaceable> only.
@@ -189,8 +189,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-t <replaceable class="parameter">table</replaceable></></term>
-      <term><option>--table=<replaceable class="parameter">table</replaceable></></term>
+      <term><option>-t</> <replaceable class="parameter">table</></term>
+      <term><option>--table=</><replaceable class="parameter">table</></term>
       <listitem>
        <para>
         Reindex <replaceable class="parameter">table</replaceable> only.
@@ -241,8 +241,8 @@ PostgreSQL documentation
 
     <variablelist>
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the server is
@@ -253,8 +253,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP port or local Unix domain socket file
@@ -265,8 +265,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable class="parameter">username</replaceable></></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></></term>
+      <term><option>-U</> <replaceable class="parameter">username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as.
@@ -311,7 +311,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--maintenance-db=<replaceable class="parameter">dbname</replaceable></></term>
+      <term><option>--maintenance-db=</><replaceable class="parameter">dbname</></term>
       <listitem>
        <para>
          Specifies the name of the database to connect to discover what other
diff --git a/doc/src/sgml/ref/vacuumdb.sgml b/doc/src/sgml/ref/vacuumdb.sgml
index 4f6fa0d..29d8504 100644
--- a/doc/src/sgml/ref/vacuumdb.sgml
+++ b/doc/src/sgml/ref/vacuumdb.sgml
@@ -134,8 +134,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-j <replaceable class="parameter">njobs</replaceable></option></term>
-      <term><option>--jobs=<replaceable class="parameter">njobs</replaceable></option></term>
+      <term><option>-j</> <replaceable class="parameter">njobs</></term>
+      <term><option>--jobs=</><replaceable class="parameter">njobs</></term>
       <listitem>
        <para>
         Execute the vacuum or analyze commands in parallel by running
@@ -168,8 +168,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-t <replaceable class="parameter">table</replaceable> [ (<replaceable class="parameter">column</replaceable> [,...]) ]</option></term>
-      <term><option>--table=<replaceable class="parameter">table</replaceable> [ (<replaceable class="parameter">column</replaceable> [,...]) ]</option></term>
+      <term><option>-t</> <replaceable class="parameter">table</> [ (<replaceable class="parameter">column</> [,...]) ]</term>
+      <term><option>--table=</><replaceable class="parameter">table</> [ (<replaceable class="parameter">column</> [,...]) ]</term>
       <listitem>
        <para>
         Clean or analyze <replaceable class="parameter">table</replaceable> only.
@@ -266,8 +266,8 @@ PostgreSQL documentation
     the following command-line arguments for connection parameters:
     <variablelist>
      <varlistentry>
-      <term><option>-h <replaceable class="parameter">host</replaceable></></term>
-      <term><option>--host=<replaceable class="parameter">host</replaceable></></term>
+      <term><option>-h</> <replaceable class="parameter">host</></term>
+      <term><option>--host=</><replaceable class="parameter">host</></term>
       <listitem>
        <para>
         Specifies the host name of the machine on which the server
@@ -278,8 +278,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-p <replaceable class="parameter">port</replaceable></></term>
-      <term><option>--port=<replaceable class="parameter">port</replaceable></></term>
+      <term><option>-p</> <replaceable class="parameter">port</></term>
+      <term><option>--port=</><replaceable class="parameter">port</></term>
       <listitem>
        <para>
         Specifies the TCP port or local Unix domain socket file
@@ -290,8 +290,8 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>-U <replaceable class="parameter">username</replaceable></></term>
-      <term><option>--username=<replaceable class="parameter">username</replaceable></></term>
+      <term><option>-U</> <replaceable class="parameter">username</></term>
+      <term><option>--username=</><replaceable class="parameter">username</></term>
       <listitem>
        <para>
         User name to connect as.
@@ -336,7 +336,7 @@ PostgreSQL documentation
      </varlistentry>
 
      <varlistentry>
-      <term><option>--maintenance-db=<replaceable class="parameter">dbname</replaceable></></term>
+      <term><option>--maintenance-db=</><replaceable class="parameter">dbname</></term>
       <listitem>
        <para>
          Specifies the name of the database to connect to discover what other
#10Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Fabien COELHO (#9)
Re: [pgsql-www] Small issue in online devel documentation build

On 2/19/17 12:34, Fabien COELHO wrote:

I wrote a few lines of perl to move replaceable out of option and did some
manual editing is special cases, the resulting simple 359 changes is
attached.

If the stylesheet produces unpleasant output, then the stylesheet should
be changed.

The current markup looks fine (to me) with the minimal default/non-web
stylesheet, so the issue is somewhere else.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#11Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Peter Eisentraut (#10)
1 attachment(s)
Re: [pgsql-www] Small issue in online devel documentation build

Hello Peter,

I wrote a few lines of perl to move replaceable out of option and did some
manual editing is special cases, the resulting simple 359 changes is
attached.

If the stylesheet produces unpleasant output, then the stylesheet should
be changed.

Sure.

I'm not sure whether it is a stylesheet issue: it is the stylesheet as
interpreted by chrome... all is fine with firefox. Whether the bug is in
chrome or the stylesheet or elsewhere is well beyond my HTML/CSS skills,
but I can ask around.

The current markup looks fine (to me) with the minimal default/non-web
stylesheet, so the issue is somewhere else.

Attached how "Google Chrome 56.0.2924.87 (Official Build) (64-bit)" on my
ubuntu laptop shows the options in of the psql dev doc using the online
css.

--
Fabien.

Attachments:

chrome_psql_dev_doc.pngimage/png; name=chrome_psql_dev_doc.pngDownload
#12Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Fabien COELHO (#11)
Re: [pgsql-www] Small issue in online devel documentation build

I'm not sure whether it is a stylesheet issue: it is the stylesheet as
interpreted by chrome... all is fine with firefox. Whether the bug is in
chrome or the stylesheet or elsewhere is well beyond my HTML/CSS skills, but
I can ask around.

After asking around, and testing with a colleague, we got the same
strange size behavior on firefox mac as well.

There are 2 possible solutions:

(1) do not nest in the first place (i.e. apply the patch I sent).

(2) do use absolute sizes in the CSS, not relative ones like "1.3em"
which accumulate multiplications when code appears in code,
and count on the navigator ctrl-+/- for users to adjust size
consistently to their needs.

--
Fabien.

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#13Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Fabien COELHO (#12)
Re: [pgsql-www] Small issue in online devel documentation build

After asking around, and testing with a colleague, we got the same strange
size behavior on firefox mac as well.

There are 2 possible solutions:

(1) do not nest in the first place (i.e. apply the patch I sent).

(2) do use absolute sizes in the CSS, not relative ones like "1.3em"
which accumulate multiplications when code appears in code,
and count on the navigator ctrl-+/- for users to adjust size
consistently to their needs.

(3) a CSS work-around, including the "!important" marker:

code code {
font-size: 100% !important;
}

This is probably the minimum fuss solution.

--
Fabien.

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#14Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Fabien COELHO (#12)
Re: [pgsql-www] Small issue in online devel documentation build

On 3/2/17 05:50, Fabien COELHO wrote:

(2) do use absolute sizes in the CSS, not relative ones like "1.3em"
which accumulate multiplications when code appears in code,
and count on the navigator ctrl-+/- for users to adjust size
consistently to their needs.

I think what you are looking at is the web site stylesheet. The whole
thing looks fine to me using the default stylesheet. On the web site,
it looks wrong to me too. I don't know what the rationale for using
1.3em for <code> is, but apparently it's not working correctly.

We could perhaps consider which markup style is better, but the problem
is that it's hard to enforce either way going forward. So we need to
find the root of the problem.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#15Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Peter Eisentraut (#14)
Re: [pgsql-www] Small issue in online devel documentation build

Hello Peter,

I think what you are looking at is the web site stylesheet.

Yep.

The whole thing looks fine to me using the default stylesheet. On the
web site, it looks wrong to me too. I don't know what the rationale for
using 1.3em for <code> is, but apparently it's not working correctly.

Indeed. The idea of relative size is to be able to adjust the size for the
whole page and have everything scale accordingly... however this mostly
works well with text, but not with images. It seems that the trend is now
to specify absolute size, and to let the browser do whole page scaling as
required by the user.

We could perhaps consider which markup style is better, but the problem
is that it's hard to enforce either way going forward. So we need to
find the root of the problem.

The root of the problem is the combination of relative size & nesting, so
one or the other has to be removed:

(1) don't nest in the input (patch I sent)
(2) don't use relative sizes (update the web site CSS)

Otherwise there are workarounds:

(3) CSS work around "code code { font-size: 100% !important; }"
(4) unnest code in the output by some postprocessing or some more
clever transformation.

--
Fabien.

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#16Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Fabien COELHO (#15)
Re: [HACKERS] Small issue in online devel documentation build

Web team, any thoughts on the CSS details?

On 3/4/17 02:00, Fabien COELHO wrote:

Hello Peter,

I think what you are looking at is the web site stylesheet.

Yep.

The whole thing looks fine to me using the default stylesheet. On the
web site, it looks wrong to me too. I don't know what the rationale for
using 1.3em for <code> is, but apparently it's not working correctly.

Indeed. The idea of relative size is to be able to adjust the size for the
whole page and have everything scale accordingly... however this mostly
works well with text, but not with images. It seems that the trend is now
to specify absolute size, and to let the browser do whole page scaling as
required by the user.

We could perhaps consider which markup style is better, but the problem
is that it's hard to enforce either way going forward. So we need to
find the root of the problem.

The root of the problem is the combination of relative size & nesting, so
one or the other has to be removed:

(1) don't nest in the input (patch I sent)
(2) don't use relative sizes (update the web site CSS)

Otherwise there are workarounds:

(3) CSS work around "code code { font-size: 100% !important; }"
(4) unnest code in the output by some postprocessing or some more
clever transformation.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#17Bruce Momjian
bruce@momjian.us
In reply to: Peter Eisentraut (#16)
Re: [HACKERS] Small issue in online devel documentation build

On Fri, Mar 10, 2017 at 11:21:33AM -0500, Peter Eisentraut wrote:

Web team, any thoughts on the CSS details?

I think I did some CSS long ago to adjust font sizes for certain font
types on our website. Should I find that?

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#18Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Bruce Momjian (#17)
Re: [HACKERS] Small issue in online devel documentation build

Hello Bruce,

On Fri, Mar 10, 2017 at 11:21:33AM -0500, Peter Eisentraut wrote:

Web team, any thoughts on the CSS details?

I think I did some CSS long ago to adjust font sizes for certain font
types on our website. Should I find that?

Dunno. Maybe?

The issue is the 1.3em associated to code, because when code is used
within code, the 1.3 multiplier accumulates and things get bigger and
bigger.

Now the font size fixing is a good thing because courrier like fonts are
somehow too small, it just must not accumulate, hence the suggested
solutions, one of which should be applied.

--
Fabien.

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#19Bruce Momjian
bruce@momjian.us
In reply to: Fabien COELHO (#18)
Re: [HACKERS] Small issue in online devel documentation build

On Sat, Mar 11, 2017 at 07:04:06AM +0100, Fabien COELHO wrote:

Hello Bruce,

On Fri, Mar 10, 2017 at 11:21:33AM -0500, Peter Eisentraut wrote:

Web team, any thoughts on the CSS details?

I think I did some CSS long ago to adjust font sizes for certain font
types on our website. Should I find that?

Dunno. Maybe?

The issue is the 1.3em associated to code, because when code is used within
code, the 1.3 multiplier accumulates and things get bigger and bigger.

Now the font size fixing is a good thing because courrier like fonts are
somehow too small, it just must not accumulate, hence the suggested
solutions, one of which should be applied.

OK, it was Javascript, not CSS. Here is what I think I did to fix the
fonts:

https://github.com/postgres/pgweb/blob/master/media/js/monospacefix.js

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#20Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Bruce Momjian (#19)
Re: [HACKERS] Small issue in online devel documentation build

Now the font size fixing is a good thing because courrier like fonts are
somehow too small, it just must not accumulate, hence the suggested
solutions, one of which should be applied.

OK, it was Javascript, not CSS. Here is what I think I did to fix the
fonts:

https://github.com/postgres/pgweb/blob/master/media/js/monospacefix.js

Indeed, this javascript does generates the faulty display based on a
dynamic evaluation of relative font sizes. That's fun.

Maybe just generate a fixed size instead so as to avoid accumulation on
nesting?

--
Fabien.

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#21Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Fabien COELHO (#15)
Re: [pgsql-www] Small issue in online devel documentation build

I think the fix belongs into the web site CSS, so there is nothing to
commit into PostgreSQL here. I will close the commit fest entry, but I
have added a section to the open items list so we keep track of it.
(https://wiki.postgresql.org/wiki/PostgreSQL_10_Open_Items#Documentation_tool_chain)

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#22Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Peter Eisentraut (#21)
Re: [pgsql-www] Small issue in online devel documentation build

Hello Peter,

I think the fix belongs into the web site CSS, so there is nothing to
commit into PostgreSQL here.

Indeed, the changes were only for the "remove nesting" solution.

I will close the commit fest entry, but I have added a section to the
open items list so we keep track of it.
(https://wiki.postgresql.org/wiki/PostgreSQL_10_Open_Items#Documentation_tool_chain)

I put forward that the quick workaround a colleague of mine suggested (aka
something like code code { font-size: 100%; important! }) could also be
applied to the web site CSS while waiting for a more definite answer which
might take some pretty unknown time close to never?

--
Fabien.

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#23Noah Misch
noah@leadboat.com
In reply to: Peter Eisentraut (#21)
Re: [pgsql-www] Small issue in online devel documentation build

On Thu, Mar 23, 2017 at 11:21:39PM -0400, Peter Eisentraut wrote:

I think the fix belongs into the web site CSS, so there is nothing to
commit into PostgreSQL here. I will close the commit fest entry, but I
have added a section to the open items list so we keep track of it.
(https://wiki.postgresql.org/wiki/PostgreSQL_10_Open_Items#Documentation_tool_chain)

[Action required within three days. This is a generic notification.]

The above-described topic is currently a PostgreSQL 10 open item. Peter,
since you committed the patch believed to have created it, you own this open
item. If some other commit is more relevant or if this does not belong as a
v10 open item, please let us know. Otherwise, please observe the policy on
open item ownership[1]/messages/by-id/20170404140717.GA2675809@tornado.leadboat.com and send a status update within three calendar days of
this message. Include a date for your subsequent status update. Testers may
discover new open items at any time, and I want to plan to get them all fixed
well in advance of shipping v10. Consequently, I will appreciate your efforts
toward speedy resolution. Thanks.

[1]: /messages/by-id/20170404140717.GA2675809@tornado.leadboat.com

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#24Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Noah Misch (#23)
Re: [pgsql-www] Small issue in online devel documentation build

On 4/5/17 02:56, Noah Misch wrote:

On Thu, Mar 23, 2017 at 11:21:39PM -0400, Peter Eisentraut wrote:

I think the fix belongs into the web site CSS, so there is nothing to
commit into PostgreSQL here. I will close the commit fest entry, but I
have added a section to the open items list so we keep track of it.
(https://wiki.postgresql.org/wiki/PostgreSQL_10_Open_Items#Documentation_tool_chain)

[Action required within three days. This is a generic notification.]

I will work on this next week. I believe I will be able to provide a
patch for the web site CSS by April 12, but ultimate success will likely
depend on the collaboration of the web team.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#25Stephen Frost
sfrost@snowman.net
In reply to: Peter Eisentraut (#24)
Re: [pgsql-www] Small issue in online devel documentation build

Peter,

* Peter Eisentraut (peter.eisentraut@2ndquadrant.com) wrote:

On 4/5/17 02:56, Noah Misch wrote:

On Thu, Mar 23, 2017 at 11:21:39PM -0400, Peter Eisentraut wrote:

I think the fix belongs into the web site CSS, so there is nothing to
commit into PostgreSQL here. I will close the commit fest entry, but I
have added a section to the open items list so we keep track of it.
(https://wiki.postgresql.org/wiki/PostgreSQL_10_Open_Items#Documentation_tool_chain)

[Action required within three days. This is a generic notification.]

I will work on this next week. I believe I will be able to provide a
patch for the web site CSS by April 12, but ultimate success will likely
depend on the collaboration of the web team.

I'm happy to try and help with this.

Thanks!

Stephen

#26Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Peter Eisentraut (#24)
Re: [pgsql-www] Small issue in online devel documentation build

(https://wiki.postgresql.org/wiki/PostgreSQL_10_Open_Items#Documentation_tool_chain)

[Action required within three days. This is a generic notification.]

I will work on this next week. I believe I will be able to provide a
patch for the web site CSS by April 12, but ultimate success will likely
depend on the collaboration of the web team.

Just to point out that as it has been decided to fix the web site CSS,
there is no expected change for pg 10 source base, so ISTM that the item
can be closed as far as pg 10 is concerned.

--
Fabien.

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#27Robert Haas
robertmhaas@gmail.com
In reply to: Fabien COELHO (#26)
Re: [pgsql-www] Small issue in online devel documentation build

On Wed, Apr 5, 2017 at 2:18 PM, Fabien COELHO <coelho@cri.ensmp.fr> wrote:

[Action required within three days. This is a generic notification.]

I will work on this next week. I believe I will be able to provide a
patch for the web site CSS by April 12, but ultimate success will likely
depend on the collaboration of the web team.

Just to point out that as it has been decided to fix the web site CSS, there
is no expected change for pg 10 source base, so ISTM that the item can be
closed as far as pg 10 is concerned.

Well, the documentation doesn't look right, currently, so I think that
should be fixed before we close this.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#28Bruce Momjian
bruce@momjian.us
In reply to: Fabien COELHO (#22)
1 attachment(s)
Re: [HACKERS] Small issue in online devel documentation build

On Fri, Mar 24, 2017 at 07:01:46AM +0100, Fabien COELHO wrote:

Hello Peter,

I think the fix belongs into the web site CSS, so there is nothing to
commit into PostgreSQL here.

Indeed, the changes were only for the "remove nesting" solution.

I will close the commit fest entry, but I have added a section to the open
items list so we keep track of it. (https://wiki.postgresql.org/wiki/PostgreSQL_10_Open_Items#Documentation_tool_chain)

I put forward that the quick workaround a colleague of mine suggested (aka
something like code code { font-size: 100%; important! }) could also be
applied to the web site CSS while waiting for a more definite answer which
might take some pretty unknown time close to never?

Sorry I am just getting back to this. Below I am going to cover only
the problem with the font size of nested <code> tags, and I am going to
confirm what most people already figured out.

The basic problem was already posted by Fabien, with an image example.
The cause of the fonts being too large on Chrome is an interaction of
Chrome's default font size for different blocks, the JavaScript that is
meant to fix such mismatches, and the new nested code blocks in the PG
10 docs.

First, the JavaScript:

https://github.com/postgres/pgweb/blob/master/media/js/monospacefix.js

There is no git history for this file except for its initial checkin in
2011, but I am pretty sure I wrote it. What it does is to create <pre>
and <p> blocks, find the font point size, and compute a ratio. If the
ratio is not 1, <pre>, <tt>, and <code> blocks are adjusted in size to
match <p>. The complex part is that the JavaScript conditionally
injects CSS into the web-page to accomplish this.

The reason the PG 10 docs look fine on Linux Firefox is because the font
points sizes match so no CSS is injected. They don't match on Chrome,
so the CSS is injected. When the CSS hits double-embedded code blocks,
<code> <code>, it makes the font too large because it double-adjusts.

The fix, as Fabien identified, is to conditionally inject additional CSS
to be _more_ specific than the first CSS and set the font-size to a
simple '1em' so the first CSS is not called twice. I don't think
'important!' is necessary but it would be good to test this.

Attached is a patch that can be applied to pgweb which should fix all of
this.

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +

Attachments:

css.difftext/x-diff; charset=us-asciiDownload
diff --git a/media/js/monospacefix.js b/media/js/monospacefix.js
new file mode 100644
index 8523932..42ce913
*** a/media/js/monospacefix.js
--- b/media/js/monospacefix.js
*************** if (newMonoSize != 1)
*** 19,24 ****
  {
          document.write('<style type="text/css" media="screen">'
  					+ '#docContainer tt, #docContainer pre, #docContainer code'
! 					+ '{font-size: ' + newMonoSize.toFixed(1) + 'em;}</style>\n');
  }
  
--- 19,27 ----
  {
          document.write('<style type="text/css" media="screen">'
  					+ '#docContainer tt, #docContainer pre, #docContainer code'
! 					+ '{font-size: ' + newMonoSize.toFixed(1) + 'em;}</style>\n'
! 					/* prevent embedded code tags from changing font size */
! 					+ '#docContainer code code'
! 					+ '{font-size: 1em;}</style>\n');
  }
  
#29Fabien COELHO
coelho@cri.ensmp.fr
In reply to: Bruce Momjian (#28)
Re: [HACKERS] Small issue in online devel documentation build

The fix, as Fabien identified, is to conditionally inject additional CSS
to be _more_ specific than the first CSS and set the font-size to a
simple '1em' so the first CSS is not called twice. I don't think
'important!' is necessary but it would be good to test this.

I did not wrote the fix, a JS-guru colleague of mine did, and he argued
that it was useful to fix priorities between competing and contradicting
CSS rules. Now maybe in this particular case it might work without it.

Attached is a patch that can be applied to pgweb which should fix all of
this.

Great, the devel doc looks ok now.

--
Fabien.

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#30Bruce Momjian
bruce@momjian.us
In reply to: Fabien COELHO (#29)
Re: [pgsql-www] Small issue in online devel documentation build

On Sat, Apr 8, 2017 at 07:33:15PM +0900, Fabien COELHO wrote:

The fix, as Fabien identified, is to conditionally inject additional CSS
to be _more_ specific than the first CSS and set the font-size to a
simple '1em' so the first CSS is not called twice. I don't think
'important!' is necessary but it would be good to test this.

I did not wrote the fix, a JS-guru colleague of mine did, and he argued that
it was useful to fix priorities between competing and contradicting CSS
rules. Now maybe in this particular case it might work without it.

It would be needed for his version because he wasn't matching the exact
tags of the CSS that the JavaScript generated.

Attached is a patch that can be applied to pgweb which should fix all of
this.

Great, the devel doc looks ok now.

Great.

What other problems do we have with pgweb that I can work on?

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#31Robert Haas
robertmhaas@gmail.com
In reply to: Bruce Momjian (#30)
Re: [HACKERS] Small issue in online devel documentation build

On Sat, Apr 8, 2017 at 6:39 AM, Bruce Momjian <bruce@momjian.us> wrote:

What other problems do we have with pgweb that I can work on?

Well, the 10devel documentation doesn't believe in orange. Compare:

https://www.postgresql.org/docs/devel/static/sql-createtable.html
https://www.postgresql.org/docs/9.6/static/sql-createtable.html

I think that needs to be fixed.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#32Bruce Momjian
bruce@momjian.us
In reply to: Robert Haas (#31)
1 attachment(s)
Re: [pgsql-www] Small issue in online devel documentation build

On Sat, Apr 8, 2017 at 12:50:19PM -0400, Robert Haas wrote:

On Sat, Apr 8, 2017 at 6:39 AM, Bruce Momjian <bruce@momjian.us> wrote:

What other problems do we have with pgweb that I can work on?

Well, the 10devel documentation doesn't believe in orange. Compare:

https://www.postgresql.org/docs/devel/static/sql-createtable.html
https://www.postgresql.org/docs/9.6/static/sql-createtable.html

I think that needs to be fixed.

The attached CSS patch will fix that specific issue, but I am unclear if
there are more places that need color.

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +

Attachments:

color.difftext/x-diff; charset=us-asciiDownload
diff --git a/media/css/text.css b/media/css/text.css
new file mode 100644
index 129735c..a910076
*** a/media/css/text.css
--- b/media/css/text.css
***************
*** 4,10 ****
  
  /* Heading Definitions */
  
! h1 {
    color: #EC5800;
  }
  
--- 4,10 ----
  
  /* Heading Definitions */
  
! h1, h2 .refentrytitle {
    color: #EC5800;
  }
  
#33Magnus Hagander
magnus@hagander.net
In reply to: Bruce Momjian (#28)
Re: [HACKERS] Small issue in online devel documentation build

On Sat, Apr 8, 2017 at 3:52 AM, Bruce Momjian <bruce@momjian.us> wrote:

On Fri, Mar 24, 2017 at 07:01:46AM +0100, Fabien COELHO wrote:

Hello Peter,

I think the fix belongs into the web site CSS, so there is nothing to
commit into PostgreSQL here.

Indeed, the changes were only for the "remove nesting" solution.

I will close the commit fest entry, but I have added a section to the

open

items list so we keep track of it. (https://wiki.postgresql.org/

wiki/PostgreSQL_10_Open_Items#Documentation_tool_chain)

I put forward that the quick workaround a colleague of mine suggested

(aka

something like code code { font-size: 100%; important! }) could also be
applied to the web site CSS while waiting for a more definite answer

which

might take some pretty unknown time close to never?

Sorry I am just getting back to this. Below I am going to cover only
the problem with the font size of nested <code> tags, and I am going to
confirm what most people already figured out.

The basic problem was already posted by Fabien, with an image example.
The cause of the fonts being too large on Chrome is an interaction of
Chrome's default font size for different blocks, the JavaScript that is
meant to fix such mismatches, and the new nested code blocks in the PG
10 docs.

First, the JavaScript:

https://github.com/postgres/pgweb/blob/master/media/js/
monospacefix.js

There is no git history for this file except for its initial checkin in
2011, but I am pretty sure I wrote it. What it does is to create <pre>
and <p> blocks, find the font point size, and compute a ratio. If the
ratio is not 1, <pre>, <tt>, and <code> blocks are adjusted in size to
match <p>. The complex part is that the JavaScript conditionally
injects CSS into the web-page to accomplish this.

There's more history in the pgweb-old repository. You can see that this
incarnation of the file actually came from Thom Brown:

https://git.postgresql.org/gitweb/?p=pgweb-old.git;a=commitdiff;h=c67090da83079be8f268564adb63e3f0d3379f29

Your was probably the version even before that one.

The reason the PG 10 docs look fine on Linux Firefox is because the font
points sizes match so no CSS is injected. They don't match on Chrome,
so the CSS is injected. When the CSS hits double-embedded code blocks,
<code> <code>, it makes the font too large because it double-adjusts.

The fix, as Fabien identified, is to conditionally inject additional CSS
to be _more_ specific than the first CSS and set the font-size to a
simple '1em' so the first CSS is not called twice. I don't think
'important!' is necessary but it would be good to test this.

Attached is a patch that can be applied to pgweb which should fix all of
this.

Is there any chance we can find a way to do this witha ctual CSS selectors
and not use javascript? I realize there might not be, but have we explored
the option properly on the way the site layout looks now and with
reasonably modern browsers?

--
Magnus Hagander
Me: https://www.hagander.net/ <http://www.hagander.net/&gt;
Work: https://www.redpill-linpro.com/ <http://www.redpill-linpro.com/&gt;

#34Magnus Hagander
magnus@hagander.net
In reply to: Bruce Momjian (#32)
Re: [HACKERS] Small issue in online devel documentation build

On Sun, Apr 9, 2017 at 2:32 AM, Bruce Momjian <bruce@momjian.us> wrote:

On Sat, Apr 8, 2017 at 12:50:19PM -0400, Robert Haas wrote:

On Sat, Apr 8, 2017 at 6:39 AM, Bruce Momjian <bruce@momjian.us> wrote:

What other problems do we have with pgweb that I can work on?

Well, the 10devel documentation doesn't believe in orange. Compare:

https://www.postgresql.org/docs/devel/static/sql-createtable.html
https://www.postgresql.org/docs/9.6/static/sql-createtable.html

I think that needs to be fixed.

The attached CSS patch will fix that specific issue, but I am unclear if
there are more places that need color.

Does this not also affect existing versions of the docs? AFAICT it would
hit any and all <h2> tags, and we certainly have those in earlier versions?

And it also modifies a global stylesheet for *all* pages. So what about the
<h2> on all the non-docs pages?

--
Magnus Hagander
Me: https://www.hagander.net/ <http://www.hagander.net/&gt;
Work: https://www.redpill-linpro.com/ <http://www.redpill-linpro.com/&gt;

#35Bruce Momjian
bruce@momjian.us
In reply to: Magnus Hagander (#34)
Re: [pgsql-www] Small issue in online devel documentation build

On Sun, Apr 9, 2017 at 07:00:38PM +0200, Magnus Hagander wrote:

On Sun, Apr 9, 2017 at 2:32 AM, Bruce Momjian <bruce@momjian.us> wrote:

On Sat, Apr� 8, 2017 at 12:50:19PM -0400, Robert Haas wrote:

On Sat, Apr 8, 2017 at 6:39 AM, Bruce Momjian <bruce@momjian.us> wrote:

What other problems do we have with pgweb that I can work on?

Well, the 10devel documentation doesn't believe in orange.� Compare:

https://www.postgresql.org/docs/devel/static/sql-createtable.html
https://www.postgresql.org/docs/9.6/static/sql-createtable.html

I think that needs to be fixed.

The attached CSS patch will fix that specific issue, but I am unclear if
there are more places that need color.

Does this not also affect existing versions of the docs? AFAICT it would hit
any and all <h2> tags, and we certainly have those in earlier versions?

It would hit any class of .refentrytitle inside of an <h2> block. I
didn't that that happened in the old docs, but I can use an href filter
to do it only for docs of versions starting with '1' or saying 'devel'.

And it also modifies a global stylesheet for *all* pages. So what about the
<h2> on all the non-docs pages?

Again, we can restrict to only certain href patterns.

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#36Bruce Momjian
bruce@momjian.us
In reply to: Magnus Hagander (#33)
Re: [pgsql-www] Small issue in online devel documentation build

On Sun, Apr 9, 2017 at 06:59:09PM +0200, Magnus Hagander wrote:

On Sat, Apr 8, 2017 at 3:52 AM, Bruce Momjian <bruce@momjian.us> wrote:
Attached is a patch that can be applied to pgweb which should fix all of
this.

Is there any chance we can find a way to do this with actual CSS selectors and
not use javascript? I realize there might not be, but have we explored the
option properly on the way the site layout looks now and with reasonably modern
browsers?

I realize that using JavaScript to insert CSS styles into an HTML
document is complex, but I know of no other way to scale a font style to
match another font style. CSS doesn't give you that control. You can
use CSS to prevent the display of certain font styles, but that hardly
seems like a win. There is probably a way to do the entire thing only
in JavaScript, but again, that doesn't seem any better.

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#37Magnus Hagander
magnus@hagander.net
In reply to: Bruce Momjian (#35)
Re: [HACKERS] Small issue in online devel documentation build

On Mon, Apr 10, 2017 at 4:02 AM, Bruce Momjian <bruce@momjian.us> wrote:

On Sun, Apr 9, 2017 at 07:00:38PM +0200, Magnus Hagander wrote:

On Sun, Apr 9, 2017 at 2:32 AM, Bruce Momjian <bruce@momjian.us> wrote:

On Sat, Apr 8, 2017 at 12:50:19PM -0400, Robert Haas wrote:

On Sat, Apr 8, 2017 at 6:39 AM, Bruce Momjian <bruce@momjian.us>

wrote:

What other problems do we have with pgweb that I can work on?

Well, the 10devel documentation doesn't believe in orange.

Compare:

https://www.postgresql.org/docs/devel/static/sql-createtable.html
https://www.postgresql.org/docs/9.6/static/sql-createtable.html

I think that needs to be fixed.

The attached CSS patch will fix that specific issue, but I am

unclear if

there are more places that need color.

Does this not also affect existing versions of the docs? AFAICT it would

hit

any and all <h2> tags, and we certainly have those in earlier versions?

It would hit any class of .refentrytitle inside of an <h2> block. I

Oh. That shows my love for css, i missed the fact that it will only hit
*subentries* with that class.
So it hits either "h1" *or* "h2" followed by something that's class
"refentrytitle".

Gotcha.

didn't that that happened in the old docs, but I can use an href filter
to do it only for docs of versions starting with '1' or saying 'devel'.

That said, doing something like this would probably be cleaner. However, I
think doing it based on href is a bad idea -- we're bound to silently break
that somehow.

What if we changed the <div id="docContent"> tag to be something like <div
id="docContent" class="post-10">

Please suggest a better name -- but the idea being we add a class do it,
conditionally for the docs of v10 and newer (which would include devel).
That way that logic stays where it belongs, and the CSS just uses the
information to style on.

Seems reasonable?

--
Magnus Hagander
Me: https://www.hagander.net/ <http://www.hagander.net/&gt;
Work: https://www.redpill-linpro.com/ <http://www.redpill-linpro.com/&gt;

#38Bruce Momjian
bruce@momjian.us
In reply to: Magnus Hagander (#37)
1 attachment(s)
Re: [HACKERS] Small issue in online devel documentation build

On Mon, Apr 10, 2017 at 10:17:26AM +0200, Magnus Hagander wrote:

didn't that that happened in the old docs, but I can use an href filter
to do it only for docs of versions starting with '1' or saying 'devel'.

That said, doing something like this would probably be cleaner. However, I
think doing it based on href is a bad idea -- we're bound to silently break
that somehow.

What if we changed the <div id="docContent"> tag to be something like <div id=
"docContent" class="post-10">�

Please suggest a better name -- but the idea being we add a class do it,
conditionally for the docs of v10 and newer (which would include devel). That
way that logic stays where it belongs, and the CSS just uses the information to
style on.

While we could trigger on some special tag, it is best to trigger on
something the build system does anyway so that if someone builds pre-10
docs with the new build system, they get the same output. The attached
patch uses:

div.refnamediv h2 .refentrytitle

and "div.refnamediv" is only generated in the new build system.

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +

Attachments:

color.difftext/x-diff; charset=us-asciiDownload
diff --git a/media/css/text.css b/media/css/text.css
new file mode 100644
index 129735c..2714f83
*** a/media/css/text.css
--- b/media/css/text.css
***************
*** 4,10 ****
  
  /* Heading Definitions */
  
! h1 {
    color: #EC5800;
  }
  
--- 4,10 ----
  
  /* Heading Definitions */
  
! h1, div.refnamediv h2 .refentrytitle {
    color: #EC5800;
  }
  
#39Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Robert Haas (#31)
2 attachment(s)
Re: [pgsql-www] Small issue in online devel documentation build

On 4/8/17 12:50, Robert Haas wrote:

On Sat, Apr 8, 2017 at 6:39 AM, Bruce Momjian <bruce@momjian.us> wrote:

What other problems do we have with pgweb that I can work on?

Well, the 10devel documentation doesn't believe in orange. Compare:

https://www.postgresql.org/docs/devel/static/sql-createtable.html
https://www.postgresql.org/docs/9.6/static/sql-createtable.html

I think that needs to be fixed.

Patch for that attached.

Also patch for improved note/warning/etc. formatting.

Another issue I saw is that tables no longer get the fancy style, e.g.,
https://www.postgresql.org/docs/devel/static/sql-syntax-lexical.html.
The style selector is table.table, which is what the build produces, but
somehow the class attribute no longer shows up on the web site.

Along with the nested <code> issue, which is already being discussed,
these are all the issues I'm aware of.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Attachments:

0001-Make-h2-orange-in-the-documentation.patchinvalid/octet-stream; name=0001-Make-h2-orange-in-the-documentation.patchDownload
From 25e4a3517ef81c50de6b092ad00a9f384358ade1 Mon Sep 17 00:00:00 2001
From: Peter Eisentraut <peter@eisentraut.org>
Date: Mon, 10 Apr 2017 22:54:13 -0400
Subject: [PATCH 1/2] Make h2 orange in the documentation

With the XSLT stylesheets, most chunk headings are not h2 instead of
formerly h1, so make h2 orange as well to match the previous style.
---
 media/css/docs.css | 1 +
 1 file changed, 1 insertion(+)

diff --git a/media/css/docs.css b/media/css/docs.css
index 10d6f48..bf57615 100644
--- a/media/css/docs.css
+++ b/media/css/docs.css
@@ -167,6 +167,7 @@ h1 {
 
 h2 {
   font-size: 1.2em !important;
+  color: #EC5800;
 }
 
 h3 {
-- 
2.12.2

0002-Improve-admonitions-style.patchinvalid/octet-stream; name=0002-Improve-admonitions-style.patchDownload
From 303e080b7c4dee8e825d5b6656e5351b73e2adf2 Mon Sep 17 00:00:00 2001
From: Peter Eisentraut <peter@eisentraut.org>
Date: Mon, 10 Apr 2017 22:55:43 -0400
Subject: [PATCH 2/2] Improve admonitions style

Make admonitions (tip, note, caution, warning) style under XSLT more
similar to previous style.  Previously, tip and note were blockquotes
and caution and warning were tables.  Now everything is just a div.
---
 media/css/docs.css | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/media/css/docs.css b/media/css/docs.css
index bf57615..8110804 100644
--- a/media/css/docs.css
+++ b/media/css/docs.css
@@ -354,6 +354,18 @@ blockquote.TIP code {
   box-shadow: none;
 }
 
+.caution,
+.warning {
+  max-width: 600px;
+}
+
+.tip h3,
+.note h3,
+.caution h3,
+.warning h3 {
+  text-align: center;
+}
+
 .emphasis,
 .c2 {
   font-weight: bold;
@@ -424,11 +436,13 @@ table.WARNING {
   max-width: 600px;
 }
 
+.caution,
 table.CAUTION {
   background-color: #F5F5DC;
   border-color: #DEDFA7;
 }
 
+.warning,
 table.WARNING {
   background-color: #FFD7D7;
   border-color: #DF421E;
-- 
2.12.2

#40Magnus Hagander
magnus@hagander.net
In reply to: Peter Eisentraut (#39)
Re: [pgsql-www] Small issue in online devel documentation build

On Tue, Apr 11, 2017 at 5:06 AM, Peter Eisentraut <
peter.eisentraut@2ndquadrant.com> wrote:

On 4/8/17 12:50, Robert Haas wrote:

On Sat, Apr 8, 2017 at 6:39 AM, Bruce Momjian <bruce@momjian.us> wrote:

What other problems do we have with pgweb that I can work on?

Well, the 10devel documentation doesn't believe in orange. Compare:

https://www.postgresql.org/docs/devel/static/sql-createtable.html
https://www.postgresql.org/docs/9.6/static/sql-createtable.html

I think that needs to be fixed.

Patch for that attached.

At the risk of being proven wrong again, won't this affect <h2> tags in the
old documentation as well? And if so, is that something we actually want?

Also patch for improved note/warning/etc. formatting.

That part looks safer.

Another issue I saw is that tables no longer get the fancy style, e.g.,
https://www.postgresql.org/docs/devel/static/sql-syntax-lexical.html.
The style selector is table.table, which is what the build produces, but
somehow the class attribute no longer shows up on the web site.

It does? The output on my laptop for that produces <table
summary="Backslash Escape Sequences" border="1"> (for example). It's
wrapped in a div with class=table. But the old code had <table border="1"
class="CALSTABLE">. And AFAICT, it's the CALSTABLE that the css is actually
matching on?

Could this be a toolchain version thing? I'm using jessie on my laptop,
which is the same one that the website is built with.

--
Magnus Hagander
Me: https://www.hagander.net/ <http://www.hagander.net/&gt;
Work: https://www.redpill-linpro.com/ <http://www.redpill-linpro.com/&gt;

#41Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Magnus Hagander (#40)
3 attachment(s)
Re: [HACKERS] Small issue in online devel documentation build

On 4/11/17 08:49, Magnus Hagander wrote:

At the risk of being proven wrong again, won't this affect <h2> tags in
the old documentation as well? And if so, is that something we actually
want?

Right. New patch with more refined selectors attached.

It does? The output on my laptop for that produces <table
summary="Backslash Escape Sequences" border="1"> (for example). It's
wrapped in a div with class=table. But the old code had <table
border="1" class="CALSTABLE">. And AFAICT, it's the CALSTABLE that the
css is actually matching on?

Could this be a toolchain version thing? I'm using jessie on my laptop,
which is the same one that the website is built with.

Seems so. Patch for that attached as well.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Attachments:

v2-0001-Make-h2-orange-in-the-documentation.patchinvalid/octet-stream; name=v2-0001-Make-h2-orange-in-the-documentation.patchDownload
From 43cbeb8093f824916a714f00e019d5b4270fab5e Mon Sep 17 00:00:00 2001
From: Peter Eisentraut <peter@eisentraut.org>
Date: Mon, 10 Apr 2017 22:54:13 -0400
Subject: [PATCH v2 1/3] Make h2 orange in the documentation

With the XSLT stylesheets, most chunk headings are not h2 instead of
formerly h1, so make h2 orange as well to match the previous style.
---
 media/css/docs.css | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/media/css/docs.css b/media/css/docs.css
index 10d6f48..dc8a068 100644
--- a/media/css/docs.css
+++ b/media/css/docs.css
@@ -185,6 +185,15 @@ h4 a:hover {
   text-decoration: none;
 }
 
+/*
+ * Change color of h2 chunk titles in XSL build.  (In DSSSL build,
+ * these will be h1, which is already handled elsewhere.)
+ */
+.titlepage h2.title,
+.refnamediv h2 {
+  color: #EC5800;
+}
+
 /* Text Styles */
 
 div.sect2,
-- 
2.12.2

v2-0002-Improve-admonitions-style.patchinvalid/octet-stream; name=v2-0002-Improve-admonitions-style.patchDownload
From 60d501a12c7329b9969ab922b39bf30459487ea5 Mon Sep 17 00:00:00 2001
From: Peter Eisentraut <peter@eisentraut.org>
Date: Mon, 10 Apr 2017 22:55:43 -0400
Subject: [PATCH v2 2/3] Improve admonitions style

Make admonitions (tip, note, caution, warning) style under XSLT more
similar to previous style.  Previously, tip and note were blockquotes
and caution and warning were tables.  Now everything is just a div.
---
 media/css/docs.css | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/media/css/docs.css b/media/css/docs.css
index dc8a068..6fb05b9 100644
--- a/media/css/docs.css
+++ b/media/css/docs.css
@@ -362,6 +362,18 @@ blockquote.TIP code {
   box-shadow: none;
 }
 
+.caution,
+.warning {
+  max-width: 600px;
+}
+
+.tip h3,
+.note h3,
+.caution h3,
+.warning h3 {
+  text-align: center;
+}
+
 .emphasis,
 .c2 {
   font-weight: bold;
@@ -432,11 +444,13 @@ table.WARNING {
   max-width: 600px;
 }
 
+.caution,
 table.CAUTION {
   background-color: #F5F5DC;
   border-color: #DEDFA7;
 }
 
+.warning,
 table.WARNING {
   background-color: #FFD7D7;
   border-color: #DF421E;
-- 
2.12.2

v2-0003-Adjust-selectors-for-table-style.patchinvalid/octet-stream; name=v2-0003-Adjust-selectors-for-table-style.patchDownload
From e49ff550e67d8d2234f4a8e34e56f47f0c63fd34 Mon Sep 17 00:00:00 2001
From: Peter Eisentraut <peter@eisentraut.org>
Date: Tue, 11 Apr 2017 10:11:55 -0400
Subject: [PATCH v2 3/3] Adjust selectors for table style

Older DocBook XSL stylesheets don't have a class on the table element,
but all versions have a surrounding div element with class "table", so
use that instead.
---
 media/css/docs.css | 18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)

diff --git a/media/css/docs.css b/media/css/docs.css
index 6fb05b9..30c1277 100644
--- a/media/css/docs.css
+++ b/media/css/docs.css
@@ -255,7 +255,7 @@ pre.literallayout,
 .warning,
 .note,
 .tip,
-table.table,
+.table table,
 pre.LITERALLAYOUT,
 .SCREEN,
 .SYNOPSIS,
@@ -390,8 +390,8 @@ table {
   margin-left: 2ex;
 }
 
-table.table td,
-table.table th,
+.table table td,
+.table table th,
 table.CALSTABLE td,
 table.CALSTABLE th,
 table.CAUTION td,
@@ -401,7 +401,7 @@ table.WARNING th {
   border-style: solid;
 }
 
-table.table,
+.table table,
 table.CALSTABLE,
 table.CAUTION,
 table.WARNING {
@@ -409,7 +409,7 @@ table.WARNING {
   border-collapse: collapse;
 }
 
-table.table,
+.table table,
 table.CALSTABLE
 {
   margin: 2ex 0 2ex 2ex;
@@ -417,19 +417,19 @@ table.CALSTABLE
   border: 2px solid #A7C6DF;
 }
 
-table.table tr:hover td,
+.table table tr:hover td,
 table.CALSTABLE tr:hover td
 {
   background-color: #EFEFEF;
 }
 
-table.table td,
+.table table td,
 table.CALSTABLE td {
   background-color: #FFF;
 }
 
-table.table td,
-table.table th,
+.table table td,
+.table table th,
 table.CALSTABLE td,
 table.CALSTABLE th {
   border: 1px solid #A7C6DF;
-- 
2.12.2

#42Magnus Hagander
magnus@hagander.net
In reply to: Peter Eisentraut (#41)
Re: [pgsql-www] Small issue in online devel documentation build

On Tue, Apr 11, 2017 at 4:30 PM, Peter Eisentraut <
peter.eisentraut@2ndquadrant.com> wrote:

On 4/11/17 08:49, Magnus Hagander wrote:

At the risk of being proven wrong again, won't this affect <h2> tags in
the old documentation as well? And if so, is that something we actually
want?

Right. New patch with more refined selectors attached.

It does? The output on my laptop for that produces <table
summary="Backslash Escape Sequences" border="1"> (for example). It's
wrapped in a div with class=table. But the old code had <table
border="1" class="CALSTABLE">. And AFAICT, it's the CALSTABLE that the
css is actually matching on?

Could this be a toolchain version thing? I'm using jessie on my laptop,
which is the same one that the website is built with.

Seems so. Patch for that attached as well.

Thanks, I've applied all three patches. Your version of the color patch
also seemed slightly more appropriate than Bruce's since it only hit the
docs.css and not the global css.

Once difference I notice is that for example the "note boxes" are no longer
centered, but they do now get the new formatting. Tables now look a lot
better.

I think that only leaves the change to the javascript code that Bruce sent.
Let's see if we can figure out a way to do that one without requiring
javascript, but after that we have covered all listed issues I think?

--
Magnus Hagander
Me: https://www.hagander.net/ <http://www.hagander.net/&gt;
Work: https://www.redpill-linpro.com/ <http://www.redpill-linpro.com/&gt;

#43Bruce Momjian
bruce@momjian.us
In reply to: Magnus Hagander (#42)
Re: [HACKERS] Small issue in online devel documentation build

On Wed, Apr 12, 2017 at 01:31:51PM +0200, Magnus Hagander wrote:

I think that only leaves the change to the javascript code that Bruce sent.
Let's see if we can figure out a way to do that one without requiring
javascript, but after that we have covered all listed issues I think?

Well, we have been using JavaScript for years, so my patch only fixes
the JavaScript we already have. Seems applying the fix now makes sense
and then we can ponder other methods.

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#44Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Magnus Hagander (#42)
Re: [pgsql-www] Small issue in online devel documentation build

On 4/12/17 07:31, Magnus Hagander wrote:

Once difference I notice is that for example the "note boxes" are no
longer centered, but they do now get the new formatting.

I have committed something for that. The issue was that the generated
HTML contained hard-coded style attributes.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#45Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Peter Eisentraut (#44)
Re: [pgsql-www] Small issue in online devel documentation build

On 4/12/17 15:43, Peter Eisentraut wrote:

On 4/12/17 07:31, Magnus Hagander wrote:

Once difference I notice is that for example the "note boxes" are no
longer centered, but they do now get the new formatting.

I have committed something for that. The issue was that the generated
HTML contained hard-coded style attributes.

This appears to have been successful.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#46Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Bruce Momjian (#43)
Re: [HACKERS] Small issue in online devel documentation build

On 4/12/17 09:50, Bruce Momjian wrote:

On Wed, Apr 12, 2017 at 01:31:51PM +0200, Magnus Hagander wrote:

I think that only leaves the change to the javascript code that Bruce sent.
Let's see if we can figure out a way to do that one without requiring
javascript, but after that we have covered all listed issues I think?

Well, we have been using JavaScript for years, so my patch only fixes
the JavaScript we already have. Seems applying the fix now makes sense
and then we can ponder other methods.

I have googled a bit. These two articles describe what I think is the
issue we are trying to address:

http://code.stephenmorley.org/html-and-css/fixing-browsers-broken-monospace-font-handling/

http://meyerweb.com/eric/thoughts/2010/02/12/fixed-monospace-sizing/

The recipe in the first one seems to work somewhat, but not quite as
well as the current javascript. (The recipe in the second article is
ultimately equivalent but more verbose.)

I tend to agree with Bruce that we could just fix this within the
current framework. But if we want to make a change, there is the
information.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#47Noah Misch
noah@leadboat.com
In reply to: Peter Eisentraut (#24)
Re: [pgsql-www] Small issue in online devel documentation build

On Wed, Apr 05, 2017 at 01:43:42PM -0400, Peter Eisentraut wrote:

On 4/5/17 02:56, Noah Misch wrote:

On Thu, Mar 23, 2017 at 11:21:39PM -0400, Peter Eisentraut wrote:

I think the fix belongs into the web site CSS, so there is nothing to
commit into PostgreSQL here. I will close the commit fest entry, but I
have added a section to the open items list so we keep track of it.
(https://wiki.postgresql.org/wiki/PostgreSQL_10_Open_Items#Documentation_tool_chain)

[Action required within three days. This is a generic notification.]

I will work on this next week. I believe I will be able to provide a
patch for the web site CSS by April 12, but ultimate success will likely
depend on the collaboration of the web team.

This PostgreSQL 10 open item is past due for your status update. Kindly send
a status update within 24 hours, and include a date for your subsequent status
update. Refer to the policy on open item ownership:
/messages/by-id/20170404140717.GA2675809@tornado.leadboat.com

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#48Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Bruce Momjian (#28)
Re: [HACKERS] Small issue in online devel documentation build

On 4/7/17 21:52, Bruce Momjian wrote:

The fix, as Fabien identified, is to conditionally inject additional CSS
to be _more_ specific than the first CSS and set the font-size to a
simple '1em' so the first CSS is not called twice. I don't think
'important!' is necessary but it would be good to test this.

Attached is a patch that can be applied to pgweb which should fix all of
this.

IMO, this patch is correct and the best way to fix this. Please proceed.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#49Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Noah Misch (#47)
Re: [pgsql-www] Small issue in online devel documentation build

On 4/14/17 01:49, Noah Misch wrote:

On Wed, Apr 05, 2017 at 01:43:42PM -0400, Peter Eisentraut wrote:

On 4/5/17 02:56, Noah Misch wrote:

On Thu, Mar 23, 2017 at 11:21:39PM -0400, Peter Eisentraut wrote:

I think the fix belongs into the web site CSS, so there is nothing to
commit into PostgreSQL here. I will close the commit fest entry, but I
have added a section to the open items list so we keep track of it.
(https://wiki.postgresql.org/wiki/PostgreSQL_10_Open_Items#Documentation_tool_chain)

[Action required within three days. This is a generic notification.]

I will work on this next week. I believe I will be able to provide a
patch for the web site CSS by April 12, but ultimate success will likely
depend on the collaboration of the web team.

This PostgreSQL 10 open item is past due for your status update. Kindly send
a status update within 24 hours, and include a date for your subsequent status
update. Refer to the policy on open item ownership:
/messages/by-id/20170404140717.GA2675809@tornado.leadboat.com

A patch for the web site CSS has been proposed but it is not getting the
same urgent attention. I will report back by Tuesday.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#50Bruce Momjian
bruce@momjian.us
In reply to: Peter Eisentraut (#49)
Re: [pgsql-www] Small issue in online devel documentation build

On Fri, Apr 14, 2017 at 11:25:48AM -0400, Peter Eisentraut wrote:

On 4/14/17 01:49, Noah Misch wrote:

On Wed, Apr 05, 2017 at 01:43:42PM -0400, Peter Eisentraut wrote:

On 4/5/17 02:56, Noah Misch wrote:

On Thu, Mar 23, 2017 at 11:21:39PM -0400, Peter Eisentraut wrote:

I think the fix belongs into the web site CSS, so there is nothing to
commit into PostgreSQL here. I will close the commit fest entry, but I
have added a section to the open items list so we keep track of it.
(https://wiki.postgresql.org/wiki/PostgreSQL_10_Open_Items#Documentation_tool_chain)

[Action required within three days. This is a generic notification.]

I will work on this next week. I believe I will be able to provide a
patch for the web site CSS by April 12, but ultimate success will likely
depend on the collaboration of the web team.

This PostgreSQL 10 open item is past due for your status update. Kindly send
a status update within 24 hours, and include a date for your subsequent status
update. Refer to the policy on open item ownership:
/messages/by-id/20170404140717.GA2675809@tornado.leadboat.com

A patch for the web site CSS has been proposed but it is not getting the
same urgent attention. I will report back by Tuesday.

Uh, unless I am missing something, I think it has been applied to pgweb,
specifically on April 12:

https://github.com/postgres/pgweb/commits/master

and this April 12 commit fixed the heading color:

https://github.com/postgres/pgweb/commit/c513457da76a4d864f706c21312d3def1fc8f8c8

I think the only open issue is the JavaScript CSS font fix that has a
posted patch here:

/messages/by-id/20170408015201.GA18573@momjian.us

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#51Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Bruce Momjian (#50)
Re: [pgsql-www] Small issue in online devel documentation build

On 4/14/17 11:35, Bruce Momjian wrote:

I think the only open issue is the JavaScript CSS font fix that has a
posted patch here:

/messages/by-id/20170408015201.GA18573@momjian.us

The open item is specifically about this issue.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#52Magnus Hagander
magnus@hagander.net
In reply to: Bruce Momjian (#28)
Re: [HACKERS] Small issue in online devel documentation build

On Sat, Apr 8, 2017 at 3:52 AM, Bruce Momjian <bruce@momjian.us> wrote:

On Fri, Mar 24, 2017 at 07:01:46AM +0100, Fabien COELHO wrote:

Hello Peter,

I think the fix belongs into the web site CSS, so there is nothing to
commit into PostgreSQL here.

Indeed, the changes were only for the "remove nesting" solution.

I will close the commit fest entry, but I have added a section to the

open

items list so we keep track of it. (https://wiki.postgresql.org/

wiki/PostgreSQL_10_Open_Items#Documentation_tool_chain)

I put forward that the quick workaround a colleague of mine suggested

(aka

something like code code { font-size: 100%; important! }) could also be
applied to the web site CSS while waiting for a more definite answer

which

might take some pretty unknown time close to never?

Sorry I am just getting back to this. Below I am going to cover only
the problem with the font size of nested <code> tags, and I am going to
confirm what most people already figured out.

The basic problem was already posted by Fabien, with an image example.
The cause of the fonts being too large on Chrome is an interaction of
Chrome's default font size for different blocks, the JavaScript that is
meant to fix such mismatches, and the new nested code blocks in the PG
10 docs.

First, the JavaScript:

https://github.com/postgres/pgweb/blob/master/media/js/
monospacefix.js

There is no git history for this file except for its initial checkin in
2011, but I am pretty sure I wrote it. What it does is to create <pre>
and <p> blocks, find the font point size, and compute a ratio. If the
ratio is not 1, <pre>, <tt>, and <code> blocks are adjusted in size to
match <p>. The complex part is that the JavaScript conditionally
injects CSS into the web-page to accomplish this.

The reason the PG 10 docs look fine on Linux Firefox is because the font
points sizes match so no CSS is injected. They don't match on Chrome,
so the CSS is injected. When the CSS hits double-embedded code blocks,
<code> <code>, it makes the font too large because it double-adjusts.

The fix, as Fabien identified, is to conditionally inject additional CSS
to be _more_ specific than the first CSS and set the font-size to a
simple '1em' so the first CSS is not called twice. I don't think
'important!' is necessary but it would be good to test this.

Attached is a patch that can be applied to pgweb which should fix all of
this.

Applied, thanks.

--
Magnus Hagander
Me: https://www.hagander.net/ <http://www.hagander.net/&gt;
Work: https://www.redpill-linpro.com/ <http://www.redpill-linpro.com/&gt;

#53Peter Eisentraut
peter.eisentraut@2ndquadrant.com
In reply to: Magnus Hagander (#52)
Re: [HACKERS] Small issue in online devel documentation build

On 4/14/17 14:45, Magnus Hagander wrote:

Attached is a patch that can be applied to pgweb which should fix all of
this.

Applied, thanks.

Oops, one </style> too many.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#54Magnus Hagander
magnus@hagander.net
In reply to: Peter Eisentraut (#53)
Re: [pgsql-www] Small issue in online devel documentation build

On Fri, Apr 14, 2017 at 9:36 PM, Peter Eisentraut <
peter.eisentraut@2ndquadrant.com> wrote:

On 4/14/17 14:45, Magnus Hagander wrote:

Attached is a patch that can be applied to pgweb which should fix

all of

this.

Applied, thanks.

Oops, one </style> too many.

Indeed. Fix pushed.

--
Magnus Hagander
Me: https://www.hagander.net/ <http://www.hagander.net/&gt;
Work: https://www.redpill-linpro.com/ <http://www.redpill-linpro.com/&gt;

#55Noah Misch
noah@leadboat.com
In reply to: Magnus Hagander (#54)
Re: Small issue in online devel documentation build

On Fri, Apr 14, 2017 at 09:38:32PM +0200, Magnus Hagander wrote:

On Fri, Apr 14, 2017 at 9:36 PM, Peter Eisentraut <peter.eisentraut@2ndquadrant.com> wrote:

On 4/14/17 14:45, Magnus Hagander wrote:

Attached is a patch that can be applied to pgweb which should fix all of
this.

Indeed. Fix pushed.

I see <replaceable> formats as italic, instead of the bold-italic seen in the
9.6 docs. (This is visible in the CREATE TABLE page, linked upthread.) Is it
worth restoring the former formatting thereof?

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www

#56Alvaro Herrera
alvherre@2ndquadrant.com
In reply to: Noah Misch (#55)
Re: [HACKERS] Small issue in online devel documentation build

Noah Misch wrote:

On Fri, Apr 14, 2017 at 09:38:32PM +0200, Magnus Hagander wrote:

On Fri, Apr 14, 2017 at 9:36 PM, Peter Eisentraut <peter.eisentraut@2ndquadrant.com> wrote:

On 4/14/17 14:45, Magnus Hagander wrote:

Attached is a patch that can be applied to pgweb which should fix all of
this.

Indeed. Fix pushed.

I see <replaceable> formats as italic, instead of the bold-italic seen in the
9.6 docs. (This is visible in the CREATE TABLE page, linked upthread.) Is it
worth restoring the former formatting thereof?

I think the bold in the original looks terrible. Regular italic looks
much nicer to me, so I'd keep it as is.

--
�lvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-www mailing list (pgsql-www@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-www