← Prev in month ← Prev in thread

orgname & orgdiv bug ?

From
Fredrik Svensson <>
Date
2006-09-27T12:17:40+00:00
ID
Thread
orgname & orgdiv bug ?
Hi,

orgname and orgdiv content is concatenated with
fo docbook stylesheet SVN id 5945.
(Debian sid Version: 1.71.0.dfsg.1-1)

It also does not work with SNAPSHOT_2006-09-26.
from http://docbook.sourceforge.net/snapshots/docbook-xsl-snapshot.zip
tested today.

I have only tested the fo stylesheet for each distribution.
I have not tested how this works with Docbook 5 and the <info> container.

Should I file it as a bug here ?
http://sourceforge.net/tracker/?group_id=21935&atid=373747
or should I just report it here.

Details :
=========

The following xml file :
============================
<?xml version="1.0" encoding='UTF-8'?>
<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
  "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd">
<article lang="en">
  <title>Test</title>
  <section>
    <sectioninfo>
      <othercredit>
	<honorific>Mr</honorific>
	<firstname>John</firstname>
	<surname>Doe</surname>
	<affiliation>
	  <shortaffil>ACNE</shortaffil>
	  <jobtitle>Worker</jobtitle>
	  <orgname>Acne Inc.</orgname>
	  <orgdiv>Work Division</orgdiv>
	</affiliation>
      </othercredit>
    </sectioninfo>
    <title>Iteresting section contributed by Mr Doe</title>
    <para>
      Testing the fo stylesheet.
    </para>
  </section>
</article>
============================

According to http://www.docbook.org/tdg/en/html/affiliation.html
affiliation ::=
(shortaffil?,jobtitle*,orgname?,orgdiv*,address*)
the tags have to be in that order.

Produces this fo with docbook.xsl
 $Id: docbook.xsl 5945 2006-05-07 07:19:24Z bobstayton $
from the Debian sid package installation.

java net.sf.saxon.Transform -o test.fo test.xml
/usr/share/xml/docbook/stylesheet/nwalsh/fo/docbook.xsl

==== cut ====
<fo:block>Mr. John Doe</fo:block><fo:block>ACNE<fo:block>Worker</fo:block>Acne
Inc.Work Division</fo:block>
==== end cut ====

Acne Inc. and Work Division is concatenated.

With a Customization layer :
============================
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:fo="http://www.w3.org/1999/XSL/Format">

<xsl:import href="/usr/share/xml/docbook/stylesheet/nwalsh/fo/docbook.xsl"/>

<xsl:template match="orgname" mode="titlepage.mode">
  <fo:block>
     <xsl:apply-templates mode="titlepage.mode"/>
  </fo:block>
</xsl:template>

<xsl:template match="orgdiv" mode="titlepage.mode">
  <fo:block>
     <xsl:apply-templates mode="titlepage.mode"/>
  </fo:block>
</xsl:template>
</xsl:stylesheet>
=============================

It they are separated. I am not sure if I add to many fo:blocks but the pdf
looks OK at least.

Mr. John Doe
ACNE
Worker
Acne Inc.
Work Division

instead of

Mr. John Doe
ACNE
Worker
Acne Inc.Work Division

/Fred
← Prev in month ← Prev in thread