From: Peter Eisentraut <peter@eisentraut.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Improve <xref> vs. <command> formatting in the documentation
Date: Sat, 03 Oct 2020 14:48:31 +0000
Message-ID: <E1kOipr-0003Eg-5a@gemulon.postgresql.org> (raw)
Improve <xref> vs. <command> formatting in the documentation
SQL commands are generally marked up as <command>, except when a link
to a reference page is used using <xref>. But the latter doesn't
create monospace markup, so this looks strange especially when a
paragraph contains a mix of links and non-links.
We considered putting <command> in the <refentrytitle> on the target
side, but that creates some formatting side effects elsewhere.
Generally, it seems safer to solve this on the link source side.
We can't put the <xref> inside the <command>; the DTD doesn't allow
this. DocBook 5 would allow the <command> to have the linkend
attribute itself, but we are not there yet.
So to solve this for now, convert the <xref>s to <link> plus
<command>. This gives the correct look and also gives some more
flexibility what we can put into the link text (e.g., subcommands or
other clauses). In the future, these could then be converted to
DocBook 5 style.
I haven't converted absolutely all xrefs to SQL command reference
pages, only those where we care about the appearance of the link text
or where it was otherwise appropriate to make the appearance match a
bit better. Also in some cases, the links where repetitive, so in
those cases the links where just removed and replaced by a plain
<command>. In cases where we just want the link and don't
specifically care about the generated link text (typically phrased
"for further information see <xref ...>") the xref is kept.
Reported-by: Dagfinn Ilmari Mannsåker <ilmari@ilmari.org>
Discussion: https://www.postgresql.org/message-id/flat/87o8pco34z.fsf@wibble.ilmari.org
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/9081bddbd75e4e8994ca243c820ca63387bd33f7
Modified Files
--------------
doc/src/sgml/backup.sgml | 8 +-
doc/src/sgml/catalogs.sgml | 98 ++++++++++++-------------
doc/src/sgml/config.sgml | 24 +++---
doc/src/sgml/ddl.sgml | 22 +++---
doc/src/sgml/dml.sgml | 2 +-
doc/src/sgml/ecpg.sgml | 7 +-
doc/src/sgml/extend.sgml | 10 +--
doc/src/sgml/logical-replication.sgml | 12 +--
doc/src/sgml/maintenance.sgml | 10 +--
doc/src/sgml/monitoring.sgml | 6 +-
doc/src/sgml/mvcc.sgml | 13 ++--
doc/src/sgml/perform.sgml | 12 +--
doc/src/sgml/plpgsql.sgml | 2 +-
doc/src/sgml/postgres-fdw.sgml | 10 +--
doc/src/sgml/queries.sgml | 2 +-
doc/src/sgml/ref/abort.sgml | 8 +-
doc/src/sgml/ref/alter_aggregate.sgml | 2 +-
doc/src/sgml/ref/alter_domain.sgml | 2 +-
doc/src/sgml/ref/alter_foreign_table.sgml | 20 ++---
doc/src/sgml/ref/alter_group.sgml | 6 +-
doc/src/sgml/ref/alter_index.sgml | 10 +--
doc/src/sgml/ref/alter_materialized_view.sgml | 3 +-
doc/src/sgml/ref/alter_role.sgml | 24 +++---
doc/src/sgml/ref/alter_statistics.sgml | 2 +-
doc/src/sgml/ref/alter_table.sgml | 32 ++++----
doc/src/sgml/ref/alter_trigger.sgml | 2 +-
doc/src/sgml/ref/alter_type.sgml | 2 +-
doc/src/sgml/ref/alter_user.sgml | 2 +-
doc/src/sgml/ref/analyze.sgml | 11 ++-
doc/src/sgml/ref/begin.sgml | 16 ++--
doc/src/sgml/ref/close.sgml | 2 +-
doc/src/sgml/ref/cluster.sgml | 4 +-
doc/src/sgml/ref/copy.sgml | 8 +-
doc/src/sgml/ref/create_aggregate.sgml | 2 +-
doc/src/sgml/ref/create_cast.sgml | 2 +-
doc/src/sgml/ref/create_database.sgml | 8 +-
doc/src/sgml/ref/create_foreign_table.sgml | 4 +-
doc/src/sgml/ref/create_function.sgml | 2 +-
doc/src/sgml/ref/create_index.sgml | 6 +-
doc/src/sgml/ref/create_language.sgml | 4 +-
doc/src/sgml/ref/create_materialized_view.sgml | 4 +-
doc/src/sgml/ref/create_operator.sgml | 4 +-
doc/src/sgml/ref/create_procedure.sgml | 2 +-
doc/src/sgml/ref/create_role.sgml | 12 +--
doc/src/sgml/ref/create_table.sgml | 12 +--
doc/src/sgml/ref/create_table_as.sgml | 10 +--
doc/src/sgml/ref/create_transform.sgml | 2 +-
doc/src/sgml/ref/create_trigger.sgml | 4 +-
doc/src/sgml/ref/create_type.sgml | 4 +-
doc/src/sgml/ref/create_user.sgml | 2 +-
doc/src/sgml/ref/create_view.sgml | 10 +--
doc/src/sgml/ref/createdb.sgml | 4 +-
doc/src/sgml/ref/createuser.sgml | 2 +-
doc/src/sgml/ref/declare.sgml | 14 ++--
doc/src/sgml/ref/delete.sgml | 2 +-
doc/src/sgml/ref/drop_group.sgml | 2 +-
doc/src/sgml/ref/drop_language.sgml | 2 +-
doc/src/sgml/ref/drop_owned.sgml | 2 +-
doc/src/sgml/ref/drop_role.sgml | 4 +-
doc/src/sgml/ref/drop_table.sgml | 4 +-
doc/src/sgml/ref/drop_user.sgml | 2 +-
doc/src/sgml/ref/dropdb.sgml | 2 +-
doc/src/sgml/ref/dropuser.sgml | 2 +-
doc/src/sgml/ref/end.sgml | 8 +-
doc/src/sgml/ref/explain.sgml | 2 +-
doc/src/sgml/ref/fetch.sgml | 4 +-
doc/src/sgml/ref/grant.sgml | 2 +-
doc/src/sgml/ref/lock.sgml | 6 +-
doc/src/sgml/ref/postgres-ref.sgml | 4 +-
doc/src/sgml/ref/prepare.sgml | 4 +-
doc/src/sgml/ref/prepare_transaction.sgml | 8 +-
doc/src/sgml/ref/psql-ref.sgml | 30 ++++----
doc/src/sgml/ref/reassign_owned.sgml | 2 +-
doc/src/sgml/ref/refresh_materialized_view.sgml | 2 +-
doc/src/sgml/ref/reindexdb.sgml | 2 +-
doc/src/sgml/ref/revoke.sgml | 4 +-
doc/src/sgml/ref/rollback.sgml | 2 +-
doc/src/sgml/ref/rollback_to.sgml | 2 +-
doc/src/sgml/ref/savepoint.sgml | 4 +-
doc/src/sgml/ref/select.sgml | 4 +-
doc/src/sgml/ref/select_into.sgml | 6 +-
doc/src/sgml/ref/set_role.sgml | 6 +-
doc/src/sgml/ref/set_session_auth.sgml | 4 +-
doc/src/sgml/ref/start_transaction.sgml | 4 +-
doc/src/sgml/ref/vacuumdb.sgml | 2 +-
doc/src/sgml/sepgsql.sgml | 8 +-
doc/src/sgml/tsm-system-rows.sgml | 2 +-
doc/src/sgml/tsm-system-time.sgml | 2 +-
doc/src/sgml/user-manag.sgml | 24 +++---
doc/src/sgml/xaggr.sgml | 2 +-
doc/src/sgml/xfunc.sgml | 12 +--
doc/src/sgml/xplang.sgml | 2 +-
92 files changed, 348 insertions(+), 346 deletions(-)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: peter@eisentraut.org
Subject: Re: pgsql: Improve <xref> vs. <command> formatting in the documentation
In-Reply-To: <E1kOipr-0003Eg-5a@gemulon.postgresql.org>
References: <E1kOipr-0003Eg-5a@gemulon.postgresql.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox