[docbook-apps] RTF doc. compilation failure due to valid XSL customizations

2009-06-10 Thread Nancy Brandt
Hi folks,


I have a document (in A5 format) that can be flawlessly
compiled in PDF format, but fails in RTF. It seems that FOP 0.94 cannot
handle background images in fo:block elements when creating an
RTF file. The following API in my print.xsl has caused this problem:


xsl:param name=chap.label.path

  select=normalize-space(//bookinfo//imageda...@role='chap_label']/@fileref)/


xsl:attribute-set name=chap.label.properties

  ...

  xsl:attribute name=background-image

    xsl:call-template name=fo-external-image

      xsl:with-param name=filename select=$chap.label.path/

    /xsl:call-template

  /xsl:attribute

  xsl:attribute name=background-attachmentfixed/xsl:attribute

  xsl:attribute name=background-repeatno-repeat/xsl:attribute

/xsl:attribute-set


FOP fails to place the chapter number on top of a background

icon. As I said, in PDF it works fine. 


When compiling RTF, I get the following error message:


WARNING: Ignored deferred event for 
org.apache.fop.fo.flow.retrievemar...@be49e0[@id=null]

May 27, 2009 4:11:44 PM org.apache.fop.render.rtf.RTFHandler startBlock

SEVERE: startBlock: null

May 27, 2009 4:11:44 PM org.apache.fop.cli.Main startFOP

SEVERE: Exception

java.lang.RuntimeException: Exception: java.lang.NullPointerException

        at org.apache.fop.cli.InputHandler.transformTo(InputHandler.java:217)

        at org.apache.fop.cli.InputHandler.renderTo(InputHandler.java:125)

        at org.apache.fop.cli.Main.startFOP(Main.java:166)

        at org.apache.fop.cli.Main.main(Main.java:197)


...


After upgrading FOP to version 0.95 the issue described further remained 
unresolved. Any ideas, folks?
Please advise!


Thank you a lot in advance


Nancy


  

[docbook-apps] Re: [docbook] Always use most specific markup?

2009-06-10 Thread Camille Bégnis
Lasse Kliemann wrote:
 Should one always use the most specific markup available?

Well, it depends ;-)
The question can be broaden: should one use inline markup at all?

It depends whether you plan to make use of that meta-information or not.
The question should be:
- Do I need to differentiate the rendering of a file name and a command
in the output documents?
- Do I need to be able to scan for all file names used in the document?
- Do others that will further use the document need that information?
- etc.

The risk with DocBook is one can be tempted to markup every word, just
because there is an element that may fit it. It can make writing a pain,
and maintaining the stylesheets too.
The answer to those questions is specific for each of us, IMHO.

If the simplified DocBook project has been unmaintained, I guess this is
because DocBook 5 makes it so easy to create its own simplified DocBook
(see http://norman.walsh.name/2005/11/05/dbtiny).

However the Publishing subcommittee may bring more answers.

Regards,

Camille.

  For 
 example, sometimes it may be conceivable to use 'systemitem' 
 instead of 'filename', 'envar', or 'function'.

 Sometimes, even, there is no more specific markup available than 
 'systemitem'. When I write a document where I am forced to use 
 'systemitem' in many places (since there is nothing more specific 
 available), it might seem unproportional to be so very specific 
 as 'filename', 'envar', etc. in other places, unless it is clear 
 that this specific markup serves a purpose.

 The Simplified Docbook Project looked as if it could offer some 
 guidance concerning such questions, but unfortunately it seems to 
 be no longer maintained. It would in general be good to have more 
 documentation and public discussion on how to use Docbook markup 
 appropriately for different purposes. Maybe we can spur some 
 development in that direction.
   

begin:vcard
fn;quoted-printable:Camille B=C3=A9gnis
n;quoted-printable:B=C3=A9gnis;Camille
org:NeoDoc
adr:;;139 rue Philippe de Girard;Pertuis;;84120;France
email;internet:cami...@neodoc.biz
tel;work:+33.9.54.96.99.55
tel;fax:+33.9.59.96.99.55
tel;cell:+33.6.33.15.10.23
url:http://www.neodoc.biz
version:2.1
end:vcard


-
To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org
For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org

[docbook-apps] list pulled out of containing para in html output

2009-06-10 Thread David Cramer
Using the 1.72.0 html xsls with para.propagates.style=1 using saxon 6.5
if I do:
 
para role=clientSome intro text:
  itemizedlist
 listitem
   paraMy listitem/para
 /listitem
  /itemizedlist
/para
 
In the output, the ul is pulled out of the containing para:
 
p class=clientSome intro text:/p
ullipMy listitem/p/li/ul
 
So I lose the ability to use the class to style the text with my css. Is
this a bug or some feature I don't understand?
 
Thanks,
David


Re: [docbook-apps] list pulled out of containing para in html output

2009-06-10 Thread Philipp Kempgen
David Cramer schrieb:
 Using the 1.72.0 html xsls with para.propagates.style=1 using saxon 6.5
 if I do:
  
 para role=clientSome intro text:
   itemizedlist
  listitem
paraMy listitem/para
  /listitem
   /itemizedlist
 /para
  
 In the output, the ul is pulled out of the containing para:
  
 p class=clientSome intro text:/p
 ullipMy listitem/p/li/ul
  
 So I lose the ability to use the class to style the text with my css. Is
 this a bug or some feature I don't understand?

That is because ul is a block-level element.
Block-level elements are not allowed inside p.

I think with make.valid.html=0 and/or html.cleanup=0 the stylesheets
don't unwrap your ul (but leave you with invalid HTML of course).

I cannot comment on whether the class should be propagated to the
ul or not, or if paras which contain block-level elements should
rather be transformed to divs instead of ps.


Philipp Kempgen
-- 
AMOOMA GmbH - Bachstr. 126 - 56566 Neuwied  -  http://www.amooma.de
Geschäftsführer: Stefan Wintermeyer, Handelsregister: Neuwied B14998
Asterisk: http://the-asterisk-book.com - http://das-asterisk-buch.de
Videos of the AMOOCON VoIP conference 2009 -  http://www.amoocon.de
-- 

-
To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org
For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org



RE: [docbook-apps] list pulled out of containing para in html output

2009-06-10 Thread David Cramer
 -Original Message-
 From: Philipp Kempgen [mailto:philipp.kemp...@amooma.de] 

snip

 That is because ul is a block-level element.
 Block-level elements are not allowed inside p.
 
 I think with make.valid.html=0 and/or html.cleanup=0 the 
 stylesheets don't unwrap your ul (but leave you with 
 invalid HTML of course).
 
 I cannot comment on whether the class should be propagated to 
 the ul or not, or if paras which contain block-level 
 elements should rather be transformed to divs instead of ps.

Ok. I see now that the xsls have to unwrap things to get valid html. I
think putting a div with the class around the unwrapped ps, uls etc.
would be the right thing to do, but it could get complicated since
ideally you'd only do it if para.propagates.style is 1 and the para
contains blocks. Otherwise, it would add a lot of unneeded divs in the
output. 

For now, xsl:template match=* mode=class.attribute gives me a hook
for propagating the style for other elements, so I just use that.

Thanks,
David 

-
To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org
For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org



Re: [docbook-apps] list pulled out of containing para in html output

2009-06-10 Thread Keith Fahlgren
On Wed, Jun 10, 2009 at 7:18 AM, David Cramerdcra...@motive.com wrote:
 Using the 1.72.0 html xsls

1.72.0 was released 869 days ago. While I'm not certain your issue
would be fixed, it would probably be easier to answer questions if you
were using a more recent version of the stylesheets. Are you able to
upgrade?


Thanks,
Keith

-
To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org
For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org



RE: [docbook-apps] list pulled out of containing para in html output

2009-06-10 Thread David Cramer
I have elaborate customization layers for several different output types
(monolithic html, chunked html, chm, eclipse, two flavors of pdf) so I
dread the merge pain and debugging of upgrading, but you're right, 2.5
years is long enough. 

Thanks,
David 

 -Original Message-
 From: Keith Fahlgren [mailto:abdela...@gmail.com] 
 Sent: Wednesday, June 10, 2009 9:59 AM
 To: David Cramer
 Cc: docbook-apps
 Subject: Re: [docbook-apps] list pulled out of containing 
 para in html output
 
 On Wed, Jun 10, 2009 at 7:18 AM, David 
 Cramerdcra...@motive.com wrote:
  Using the 1.72.0 html xsls
 
 1.72.0 was released 869 days ago. While I'm not certain your 
 issue would be fixed, it would probably be easier to answer 
 questions if you were using a more recent version of the 
 stylesheets. Are you able to upgrade?
 
 
 Thanks,
 Keith
 

-
To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org
For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org



[docbook-apps] TOC generation stopped after moving to stylesheet version 1.75.1

2009-06-10 Thread Ravindra Wankar


I was using 1.71.1 with the following customizations. Now I get an empty 
TOC with version 1.75.1. This happens only in the HTML output. Works 
fine with PDF. I can also confirm that switching back to 1.71.1 restores 
the TOC. Any clues?


 xsl:param name=section.autolabel select='1'/
 xsl:param name=section.autolabel.max.depth select='3'/
 xsl:param name=section.label.includes.component.label select='1'/
 xsl:param name=use.extensions select='0'/
 xsl:param name=fop.extensions select='0'/
 xsl:param name=fop1.extensions select='1'/
 xsl:param name=xref.with.number.and.title select=1/
 xsl:param name=insert.xref.page.number select='1'/
 xsl:param name=variablelist.as.blocks select='1'/
 xsl:param name=suppress.header.navigation select=0/
 xsl:param name=generate.section.toc.level select=1/
 xsl:param name=toc.section.depth select=2/
 xsl:param name=admon.graphics select=1/xsl:param
 xsl:param name=annotate.toc0/xsl:param
 xsl:param name=formal.procedures select=0/xsl:param
 xsl:attribute-set name=xref.properties
   xsl:attribute name=text-decorationunderline/xsl:attribute
   xsl:attribute name=colorblue/xsl:attribute
 /xsl:attribute-set
 xsl:param name=local.l10n.xml select=document('')/
 l:i18n xmlns:l=http://docbook.sourceforge.net/xmlns/l10n/1.0;
   l:l10n language=en
 l:context name=xref-number-and-title
   l:template name=sect3 text=%t (Section %n)/
   l:template name=section text=%t (Section %n)/
   l:template name=chapter text=%t (Chapter %n)/
 /l:context
   /l:l10n
 /l:i18n
 xsl:param name=formal.title.placement
   figure after
 /xsl:param

 xsl:param name=menuchoice.menu.separator#x2192;/xsl:param

 xsl:param name=generate.toc
appendix  nop
article   toc,title
book  toc,title,figure,table,example,equation
chapter   toc,title
part  nop
preface   nop
qandadiv  nop
qandaset  nop
reference toc,title
section   toc,title
set   toc
 /xsl:param

 xsl:param name=admon.graphics.path../../images//xsl:param
 xsl:output method=html encoding=UTF-8 indent=no/
 xsl:include href=celoxis-customizations.xsl/
 xsl:param name=html.stylesheet select='../../style.css'/
 xsl:param name=use.id.as.filename select='1'/
 xsl:param name=section.autolabel.max.depth select=2/xsl:param
 xsl:param name=chunk.section.depth select='2'/
 xsl:param name=chunk.first.sections select='2'/
 xsl:param name=chunk.fast select='1'/
 xsl:param name=chunk.quietly select='0'/

Thanks,
-- Ravi

-
To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org
For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org