gnome-db2html3 explained



--- Begin Message ---
Eric -

First, apologies. It's been so long since I dealt with this I was a
bit rusty on the details, and my explanation last night was
poor/wrong. I had to go back to the code - it's been six months since
I thought about any of this.

gnome-db2html acts essentially the same as xsltproc with a couple of
important exceptions. For the discussion below, I'll give you the
equivalent xsltproc commands so you can see what it's doing.

It needs to construct href's with the full path to the doc, not just
ghelp:docname as I said last night. (If it would be easier or more
practical to just use "docname" I believe I could rewrite the C to do
that, but for some reason that I don't remember this was the better
way to do it).

Because xslt doesn't have access to the filename it's parsing, I feed
the path and filename in as parameters. That's what:

<xsl:param name="gdb_docname" />
and
<xsl:param name="gdb_pathname" />

are at the beginning of gnome-customization.xsl.

It also looks at the ghelp uri: "ghelp:docname?id" looking for the "?"
and, if it's there, makes a note of the fact and grabs the id.

It then feeds all this stuff as parameters to gnome-db2html in a way
that's equivalent to:

xsltproc --catalogs --stringparam gdb_pathname /path/to/ --stringparam
gdb_docname docname.xml --stringparam  rootid id
[PREFIX]/share/sgml/docbook/gnome-customization-0.1/gnome-customization.xsl
/path/to/docname.xml

If there is no "?id", it doesn't feed the rootid bit.

I don't know if you've dealt with it, but the rootid parameter in NW's
stylesheets tells them to only output the bit (sect, chapter,
whatever) named by the id.

Hope this is helpful. I'm cc'ing myself so I can save a copy. :-)

Cheers,

John


--- End Message ---


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]