pg.ddx.io pgsql-docs@postgresql.org mailing list archive
help / color / mirror / Atom feedAn XSLT example script
8+ messages / 4 participants
[nested] [flat]
Commits from this thread:
2020-04-21 f8ba8dddb4 f7b2e04a60 f192312dc0 71ae1a89d2 ef27e304f2 de56dafeed doc: change SGML markup "figure" to "example"
* An XSLT example script
@ 2020-04-14 08:03 Jürgen Purtz <juergen@purtz.de>
0 siblings, 2 replies; 8+ messages in thread
From: Jürgen Purtz @ 2020-04-14 08:03 UTC (permalink / raw)
To: pgsql-docs@lists.postgresql.org
The example "XSLT Stylesheet for Converting SQL/XML Output to HTML" is
tagged as <figure>, but it isn't a figure, it's an example script. The
PDF output contains lists for examples, figures and tables and shows it
in the wrong list. We should change the tagging.
Jürgen P.
Attachments:
0001-xslt-example.patch (text/x-patch, 577B) download
diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml
index 7a270eb0ab..2f1cf46c2a 100644
--- a/doc/src/sgml/func.sgml
+++ b/doc/src/sgml/func.sgml
@@ -11499,7 +11499,7 @@ table2-mapping
converted into other XML-based formats.
</para>
- <figure id="xslt-xml-html">
+ <example id="xslt-xml-html">
<title>XSLT Stylesheet for Converting SQL/XML Output to HTML</title>
<programlisting><![CDATA[
<?xml version="1.0"?>
@@ -11547,7 +11547,7 @@ table2-mapping
</xsl:stylesheet>
]]></programlisting>
- </figure>
+ </example>
</sect2>
</sect1>
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: An XSLT example script
@ 2020-04-21 01:41 Bruce Momjian <bruce@momjian.us>
parent: Jürgen Purtz <juergen@purtz.de>
1 sibling, 0 replies; 8+ messages in thread
From: Bruce Momjian @ 2020-04-21 01:41 UTC (permalink / raw)
To: Jürgen Purtz <juergen@purtz.de>; +Cc: pgsql-docs@lists.postgresql.org
On Tue, Apr 14, 2020 at 10:03:53AM +0200, Jürgen Purtz wrote:
> The example "XSLT Stylesheet for Converting SQL/XML Output to HTML" is
> tagged as <figure>, but it isn't a figure, it's an example script. The PDF
> output contains lists for examples, figures and tables and shows it in the
> wrong list. We should change the tagging.
Agreed. Backpatched through 9.5. Thanks.
---------------------------------------------------------------------------
>
>
> Jürgen P.
>
>
> diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml
> index 7a270eb0ab..2f1cf46c2a 100644
> --- a/doc/src/sgml/func.sgml
> +++ b/doc/src/sgml/func.sgml
> @@ -11499,7 +11499,7 @@ table2-mapping
> converted into other XML-based formats.
> </para>
>
> - <figure id="xslt-xml-html">
> + <example id="xslt-xml-html">
> <title>XSLT Stylesheet for Converting SQL/XML Output to HTML</title>
> <programlisting><![CDATA[
> <?xml version="1.0"?>
> @@ -11547,7 +11547,7 @@ table2-mapping
>
> </xsl:stylesheet>
> ]]></programlisting>
> - </figure>
> + </example>
> </sect2>
> </sect1>
>
--
Bruce Momjian <bruce@momjian.us> https://momjian.us
EnterpriseDB https://enterprisedb.com
+ As you are, so once was I. As I am, so you will be. +
+ Ancient Roman grave inscription +
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: An XSLT example script
@ 2020-04-21 18:10 Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
parent: Jürgen Purtz <juergen@purtz.de>
1 sibling, 2 replies; 8+ messages in thread
From: Peter Eisentraut @ 2020-04-21 18:10 UTC (permalink / raw)
To: Jürgen Purtz <juergen@purtz.de>; pgsql-docs@lists.postgresql.org
On 2020-04-14 10:03, Jürgen Purtz wrote:
> The example "XSLT Stylesheet for Converting SQL/XML Output to HTML" is
> tagged as <figure>, but it isn't a figure, it's an example script.
It's not an example, it's an actual script that you are supposed to use.
> The
> PDF output contains lists for examples, figures and tables and shows it
> in the wrong list. We should change the tagging.
Why is it wrong to make this a figure?
--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: An XSLT example script
@ 2020-04-21 19:04 Bruce Momjian <bruce@momjian.us>
parent: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
1 sibling, 1 reply; 8+ messages in thread
From: Bruce Momjian @ 2020-04-21 19:04 UTC (permalink / raw)
To: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>; +Cc: Jürgen Purtz <juergen@purtz.de>; pgsql-docs@lists.postgresql.org
On Tue, Apr 21, 2020 at 08:10:09PM +0200, Peter Eisentraut wrote:
> On 2020-04-14 10:03, Jürgen Purtz wrote:
> > The example "XSLT Stylesheet for Converting SQL/XML Output to HTML" is
> > tagged as <figure>, but it isn't a figure, it's an example script.
>
> It's not an example, it's an actual script that you are supposed to use.
Uh, the text said "example", and all the other figures we had used SVG
files, so it didn't see to match our other markup.
> > The
> > PDF output contains lists for examples, figures and tables and shows it
> > in the wrong list. We should change the tagging.
>
> Why is it wrong to make this a figure?
I thought figure was just images. Was figure really right, or something
else? This is the only script we use? programlisting maybe?
--
Bruce Momjian <bruce@momjian.us> https://momjian.us
EnterpriseDB https://enterprisedb.com
+ As you are, so once was I. As I am, so you will be. +
+ Ancient Roman grave inscription +
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: An XSLT example script
@ 2020-04-21 19:23 Jürgen Purtz <juergen@purtz.de>
parent: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
1 sibling, 0 replies; 8+ messages in thread
From: Jürgen Purtz @ 2020-04-21 19:23 UTC (permalink / raw)
To: pgsql-docs@lists.postgresql.org
On 21.04.20 20:10, Peter Eisentraut wrote:
> On 2020-04-14 10:03, Jürgen Purtz wrote:
>> The example "XSLT Stylesheet for Converting SQL/XML Output to HTML" is
>> tagged as <figure>, but it isn't a figure, it's an example script.
>
> It's not an example, it's an actual script that you are supposed to use.
>
>> The
>> PDF output contains lists for examples, figures and tables and shows it
>> in the wrong list. We should change the tagging.
>
> Why is it wrong to make this a figure?
>
Sorry, I don't understand. Do we speak about the same position in the
documentation?
https://www.postgresql.org/docs/12/functions-xml.html#XSLT-XML-HTML
Scripts usually are tagged as "screen", "programmlisting", "example",
"synopsis/function" (for functions) - but never as a figure. The
introductory text explicitly says "As an example ...". Therefor
"example" seems to be appropriate. IMO "programmlisting" is also possible.
And: there is no single graphical element like a line, a circle, a
color, or an UML-symbol.
--
Jürgen Purtz
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: An XSLT example script
@ 2020-04-23 09:40 Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
parent: Bruce Momjian <bruce@momjian.us>
0 siblings, 1 reply; 8+ messages in thread
From: Peter Eisentraut @ 2020-04-23 09:40 UTC (permalink / raw)
To: Bruce Momjian <bruce@momjian.us>; +Cc: Jürgen Purtz <juergen@purtz.de>; pgsql-docs@lists.postgresql.org
On 2020-04-21 21:04, Bruce Momjian wrote:
> On Tue, Apr 21, 2020 at 08:10:09PM +0200, Peter Eisentraut wrote:
>> On 2020-04-14 10:03, Jürgen Purtz wrote:
>>> The example "XSLT Stylesheet for Converting SQL/XML Output to HTML" is
>>> tagged as <figure>, but it isn't a figure, it's an example script.
>>
>> It's not an example, it's an actual script that you are supposed to use.
>
> Uh, the text said "example", and all the other figures we had used SVG
> files, so it didn't see to match our other markup.
>
>>> The
>>> PDF output contains lists for examples, figures and tables and shows it
>>> in the wrong list. We should change the tagging.
>>
>> Why is it wrong to make this a figure?
>
> I thought figure was just images. Was figure really right, or something
> else? This is the only script we use? programlisting maybe?
Maybe it's just easier to remove the wrapping in either <figure> or
<example> if that is confusing.
But I request that the backpatching of this be reverted. This would
renumber all the other examples and/or figures, and then it won't be
clear what future bug reports will refer to. This issue isn't that
drastic to make that worth it.
--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: An XSLT example script
@ 2020-04-23 15:16 Jürgen Purtz <juergen@purtz.de>
parent: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
0 siblings, 1 reply; 8+ messages in thread
From: Jürgen Purtz @ 2020-04-23 15:16 UTC (permalink / raw)
To: pgsql-docs@lists.postgresql.org
On 23.04.20 11:40, Peter Eisentraut wrote:
>
> Maybe it's just easier to remove the wrapping in either <figure> or
> <example> if that is confusing.
>
> But I request that the backpatching of this be reverted. This would
> renumber all the other examples and/or figures, and then it won't be
> clear what future bug reports will refer to. This issue isn't that
> drastic to make that worth it.
This is a tiny patch, backpatching isn't important for me.
The chapter doesn't contain any other example or figure. Therefore we
shouldn't face any side effect concerning numbering. Those numbers
restart in every chapter for figures, examples, and tables (there is an
additional table in the huge list of tables of this chapter: "Bit String
Functions" after "Bit String Operators").
--
Jürgen Purtz
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: An XSLT example script
@ 2020-04-23 15:40 Tom Lane <tgl@sss.pgh.pa.us>
parent: Jürgen Purtz <juergen@purtz.de>
0 siblings, 0 replies; 8+ messages in thread
From: Tom Lane @ 2020-04-23 15:40 UTC (permalink / raw)
To: Jürgen Purtz <juergen@purtz.de>; +Cc: pgsql-docs@lists.postgresql.org, Peter Eisentraut <peter.eisentraut@2ndquadrant.com>; Bruce Momjian <bruce@momjian.us>
=?UTF-8?Q?J=c3=bcrgen_Purtz?= <juergen@purtz.de> writes:
> On 23.04.20 11:40, Peter Eisentraut wrote:
>> But I request that the backpatching of this be reverted. This would
>> renumber all the other examples and/or figures, and then it won't be
>> clear what future bug reports will refer to. This issue isn't that
>> drastic to make that worth it.
> The chapter doesn't contain any other example or figure. Therefore we
> shouldn't face any side effect concerning numbering. Those numbers
> restart in every chapter for figures, examples, and tables (there is an
> additional table in the huge list of tables of this chapter: "Bit String
> Functions" after "Bit String Operators").
Yeah, Peter's point would be a good one if there were other <figure>s
or <example>s in chapter 9, but there are none today.
I personally wouldn't have bothered with back-patching on the grounds
of "it's unimportant" ... but now that it's done, I wouldn't revert it,
on the same grounds.
regards, tom lane
^ permalink raw reply [nested|flat] 8+ messages in thread
end of thread, other threads:[~2020-04-23 15:40 UTC | newest]
Thread overview: 8+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2020-04-14 08:03 An XSLT example script Jürgen Purtz <juergen@purtz.de>
2020-04-21 01:41 ` Bruce Momjian <bruce@momjian.us>
2020-04-21 18:10 ` Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
2020-04-21 19:04 ` Bruce Momjian <bruce@momjian.us>
2020-04-23 09:40 ` Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
2020-04-23 15:16 ` Jürgen Purtz <juergen@purtz.de>
2020-04-23 15:40 ` Tom Lane <tgl@sss.pgh.pa.us>
2020-04-21 19:23 ` Jürgen Purtz <juergen@purtz.de>
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