July, 2008

Commit #130593 by robertDouglass at 14:51
Export DocBook: /modules/exportdocbook/exportdocbook.module 1.5.2.8 @ DRUPAL-5
Stub code for a more configurable book export. The code has an admin page that has no functionality. However, it does build a representation of all the book hierarchies and invoke a hook so that other modules can tie into it. My hope is to turn this into a tool by which modules can add appendicies, glossaries, articles, and other items to the book.

Commit #130560 by robertDouglass at 10:47
Export DocBook: /modules/export_docbook/h2db.xsl 1.1.4.23 @ DRUPAL-5
Refactored code to generate indexterms into its own template. This lets me call the template for dfn elements as well, which can be generated by the Glossary module. This (eventually) is going to lead to books with Glossaries and automatically generated indexes based on the glossary terms.

Commit #130526 by robertDouglass at 05:52
Export DocBook: /modules/export_docbook/h2db.xsl 1.1.4.19 @ DRUPAL-5
Turns out, not checking to see whether the element was a real element name was a mistake. The set is now limited to footnote|sidebar|tip|caution|warning|important|note.

Commit #130525 by robertDouglass at 05:36
Export DocBook: /modules/export_docbook/h2db.xsl 1.1.4.18 @ DRUPAL-5
Unify DIV and SPAN handling. Instead of trying to enumerate all of the possible DocbookXML elements that we might want to include, andy div or span tag with a class name of docbook-foo will create a foo element (there’s no checking to make sure foo is a real element!). The first <h2> becomes the title. Any text not wrapped in an element gets a <para> wrapper.

Commit #130404 by robertDouglass at 16:25
Export DocBook: /modules/export_docbook/h2db.xsl 1.1.4.15 @ DRUPAL-5
Support for end-of-book indexes. This is a bit of a hack but works well enough for most purposes. To make an end-of-book index you need two things. An <index/> tag somewhere in the book (this now gets added), and <indexterm> elements in the Docbook XML. The trick here is twofold. <indexterm> elements can have <primary>, <secondary> and <tertiary> elements that make nice nested indexes.

Commit #130393 by robertDouglass at 15:46
Export DocBook: /modules/export_docbook/h2db.xsl 1.1.4.14 @ DRUPAL-5
Refine sidebar handling to be as "smart" as the footnote handling with regards to paragraphs. Docbook XML requires paragraphs… XHTML doesn’t.

Commit #130344 by robertDouglass at 12:31
Export DocBook: /modules/export_docbook/h2db.xsl 1.1.4.12 @ DRUPAL-5
Sidebar support =) Use <div class="docbook-sidebar"><h2>Title goes here</h2> etc…. </div>

Commit #130338 by robertDouglass at 10:57
Export DocBook: /modules/export_docbook/h2db.xsl 1.1.4.10 @ DRUPAL-5
Inline media objects left the same but normal mediaobjects now get embedded in figure tags. The figure’s title gets taken from the alt param of the image. (missed a line of commented code)

Commit #130337 by robertDouglass at 10:56
Export DocBook: /modules/export_docbook/h2db.xsl 1.1.4.9 @ DRUPAL-5
Inline media objects left the same but normal mediaobjects now get embedded in figure tags. The figure’s title gets taken from the alt param of the image.

Commit #130174 by robertDouglass at 14:33
Export DocBook: /modules/export_docbook/h2db.xsl 1.1.4.8 @ DRUPAL-5
So the practical solution is to give up on using the Docbook anchor element and use paragraphs instead. This makes the links work in PDFs, which is nice.

Commit #130169 by robertDouglass at 13:55
Export DocBook: /modules/export_docbook/h2db.xsl 1.1.4.7 @ DRUPAL-5
HACK: even though Docbook 4.5 says anchors can be children of just about anything, including chapters, they cause processing errors at the fop layer (fo:inline can’t be a child of fo:flow). This hack, to wrap the anchor in a <para> element, needs a better solution, but at least you can generate a PDF from the output XML

Commit #130164 by robertDouglass at 13:18
Export DocBook: /modules/export_docbook/h2db.xsl 1.1.4.5 @ DRUPAL-5
Now named anchor tags in HTML become Docbook anchor tags with an id. However, at least in my fo processing, the linkend property of link tags don’t find the id property of the anchor element. This gives me an Unresolved id reference "foo" found. error. Is this a matter of needing to somehow define id as type ID at the XML level? If you know, contact me, plz.

Commit #130157 by robertDouglass at 11:22
Export DocBook: /modules/export_docbook/h2db.xsl 1.1.4.3 @ DRUPAL-5
Rearrange the xslt. Comment out a ‘workbench hack’ that looked rather specific to the original author’s needs and might result in interesting surprises. Otherwise no functional change.