Re: [docbook-apps] What is Xml ?
Dear Richard, For autoritative source, quote http://www.w3.org/standards/xml/core HTH alberto On Mon, Jul 30, 2012 at 1:51 PM, Kerry, Richard richard.ke...@atos.net wrote: Stefan, Thanks for that, but I know most of it already. The issue is that if I'm to get the supplier to change their software or docs I'll need to be able refer to an authoritative source. Appreciatlvely, Richard. -Original Message- From: Stefan Hinz [mailto:stefan.h...@oracle.com] Sent: 30 July 2012 13:45 To: docbook-apps@lists.oasis-open.org Subject: Re: [docbook-apps] What is Xml ? Hi Richard, Please can someone direct me to an authoritative explanation of what constitutes a valid XML file ? Let me try with expert knowledge freshly gained from Wikipedia (http://en.wikipedia.org/wiki/XML#Well-formedness_and_error-handling). For your below document, this means: * The ?xml? prolog is optional. * There's no single root element that contains all the other elements. Therefore, the XML isn't well-formed, and thus not valid. HTH. Cheers, Stefan I've been provided with some XML files which are a bit like this : ?xml? category id=information section id=general element id=fileinfo / /section /category category id=device section id=Status element id=1 / element id=2 / /section /category They are described as XML, together with a note that ... file can be created using any XML editor providing the format and tags required are used, though I get various errors from emacs+nxml-mode, XmlMind and Serna. I think that they are not well-formed, on account of having two root nodes. I'm also a bit surprised by the lack of the usual version, encoding and standalone attributes in the xml PI, though I suspect they are actually optional. And I've just found that it starts with (hex) ef bb bf, before the ? - is that a byte-order mark ? Or just another non-standardness ? I will need to pass this back to the originators so that they can either : 1. Change their software to produce/use real XML. or: 2. Change their documentation to refer to XML-like or similar. In the meantime I'll need to do some sort of processing to get it into a form that I can process. Appreciatively, Richard. Blue line *Richard Kerry* BNCS Engineer T: +44 (0)20 82259063 M: +44 (0)7812 325518 Room EBX 301, BBC Television Centre, Wood Lane, London, W12 7RJ richard.ke...@atos.net mailto:richard.ke...@atos.net uk.atos.net http://uk.atos.net/en-uk/ Atos logo This e-mail and the documents attached are confidential and intended solely for the addressee; it may also be privileged. If you receive this e-mail in error, please notify the sender immediately and destroy it. As its integrity cannot be secured on the Internet, the Atos group liability cannot be triggered for the message content. Although the sender endeavours to maintain a computer virus-free network, the sender does not warrant that this transmission is virus-free and will not be liable for any damages resulting from any virus transmitted. -- Cheers, Stefan Hinz stefan.h...@oracle.com, MySQL Documentation Manager Phone: +49-30-82702940, Fax: +49-30-82702941, http://dev.mysql.com/doc ORACLE Deutschland B.V. Co. KG Registered Office: Riesstr. 25, 80992 Muenchen, Germany Commercial Register: Local Court Of Munich, HRA 95603 Managing Director: Jürgen Kunz General Partner: ORACLE Deutschland Verwaltung B.V. Hertogswetering 163/167, 3543 AS Utrecht, Niederlande Register Of Chamber Of Commerce: Midden-Niederlande, No. 30143697 Managing Directors: Alexander van der Ven, Astrid Kepper, Val Maher - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org -- Alberto Simões - 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] Yet again, FOP complaining of the generated fo file
Hello, friends As you might recall, I shared some trouble I was having with FOP and conversion of a .fo file to .pdf. Bob helped finding the problem, I reported to FOP developers, and it was fixed today on trunk. But now, I have some other problems, and I would like to hear from you wether or not this might be a bug of FOP, so I can report again :) FOP complains with: javax.xml.transform.TransformerException: org.apache.fop.fo.ValidationException: fo:list-item-label is missing child elements. Required content model: marker* (%block;)+ (See position 10949:732) The complain is correct, as the generated code is: fo:list-item space-after=0pt space-before.minimum=0.5em space-before.optimum=1em space-before.maximum=2em space-after.minimum=0.5em space-after.optimum=1em space-after.maximum=2emfo:list-item-label/fo:list-item-body start-indent=0pt end-indent=0ptfo:block-container width=100% height=2info:block Now, the quesiton is, is it correct that the label should have a content? Thank you for pointers, Alberto -- Alberto Simões - 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] Yet again, FOP complaining of the generated fo file
On Tue, Apr 3, 2012 at 6:08 PM, Bob Stayton b...@sagehill.net wrote: Yes, the standard has a content model of (%block;)+, which means it should not be empty. What DocBook XML is triggering that output? It links to the listitem close/open sequence: [...] programlisting format=linespecific id=I_programlisting_appa_tt72 language=perl xml:space=preserveprint Would link '$source' to '$dest'.\n;/programlisting /listitem ?dbfo-need height=”2in” ? listitem paraHere’s one way to do it:/para programlisting format=linespecific id=I_programlisting_appa_tt73 language=perl xml:space=preserveuse File::Basename; [...] Thanks - 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] Yet again, FOP complaining of the generated fo file
On Tue, Apr 3, 2012 at 7:26 PM, Bob Stayton b...@sagehill.net wrote: Thanks for pointing out the ?dbfo need?. That is indeed the item that is generating the empty list-item-label. I'll fix that in the source tree. Great. So, can I pull the fix from somewhere :) Regarding dbfo needs in FOP, the last time I tried it I found it is close to working. The basic mechanism works, but it does not properly preserve the vertical spacing because FOP did not support certain spacing properties, but which ones I don't recall at this moment. It is possible they have fixed those spacing properties, in which case it should work. If you test it, let me know what your results are. Just a note for people reading my mails to this list, I am not writing the document myself, but translating from an O'Reilly book. So, for now, I prefer not to mess with any XML/XML-PI, and do that only when I get to the end. Thank you Alberto Bob Stayton Sagehill Enterprises b...@sagehill.net - Original Message - From: David Cramer da...@thingbag.net To: docbook-apps@lists.oasis-open.org Sent: Tuesday, April 03, 2012 11:17 AM Subject: Re: [docbook-apps] Yet again, FOP complaining of the generated fo file -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 04/03/2012 12:13 PM, Alberto Simões wrote: ?dbfo-need height=”2in” ? I was under the impression that the dbfo-need doesn't work with fop (though I don't know if it causes harm). If it works now, I'd be interested in using it. Thanks, David -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEcBAEBAgAGBQJPez69AAoJEMHeSXG7afUhR1wH/RcnZzlTqBSic7QPIlurIXGE RDywDamce+mq90wT26NQs8YKVJO+auxiqzBTyGbHGwzu+H5/BGs9sm3Mi3b9LbEC J04f+tptQu8qFmk8rMhQQ/nItAI9e3e432M9k+gQl9b2NY0ZqEkTU4pqcrfShmcg 5lV7Oh49FOIZmS4anYORg+hxT9uYatY1TTP7SnysyzEuKJznJ4ExByzNQmtFlVdU S88pNlJR+27d1YzdD9oiwz1O+fZ03NCuPXwxr2P2FtMYIi+sK16C7rCOoMXgr1vT +bGqQ9+i1VZimf31YVCHXBDvebeXjY5pII2Rw537zQNrWUvfRpZhr4ofX4jfBJw= =Qd2V -END PGP SIGNATURE- - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org -- Alberto Simões - 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] Yet again, FOP complaining of the generated fo file
Bob, did you commit? :) http://docbook.svn.sourceforge.net/viewvc/docbook/trunk/xsl/?view=log doesn't list any changes for today. Thanks On Tue, Apr 3, 2012 at 8:08 PM, Bob Stayton b...@sagehill.net wrote: Oh, if you want to test with FOP1 and stylesheet version 1.76.1 or snapshot, you need to edit the template for dbfo need in fo/pi.xsl, because it has an xsl:when clause to skip any need PIs when fop1.extensions != 0. Bob Stayton Sagehill Enterprises b...@sagehill.net - Original Message - From: David Cramer da...@thingbag.net To: docbook-apps@lists.oasis-open.org Sent: Tuesday, April 03, 2012 11:17 AM Subject: Re: [docbook-apps] Yet again, FOP complaining of the generated fo file -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 04/03/2012 12:13 PM, Alberto Simões wrote: ?dbfo-need height=”2in” ? I was under the impression that the dbfo-need doesn't work with fop (though I don't know if it causes harm). If it works now, I'd be interested in using it. Thanks, David -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEcBAEBAgAGBQJPez69AAoJEMHeSXG7afUhR1wH/RcnZzlTqBSic7QPIlurIXGE RDywDamce+mq90wT26NQs8YKVJO+auxiqzBTyGbHGwzu+H5/BGs9sm3Mi3b9LbEC J04f+tptQu8qFmk8rMhQQ/nItAI9e3e432M9k+gQl9b2NY0ZqEkTU4pqcrfShmcg 5lV7Oh49FOIZmS4anYORg+hxT9uYatY1TTP7SnysyzEuKJznJ4ExByzNQmtFlVdU S88pNlJR+27d1YzdD9oiwz1O+fZ03NCuPXwxr2P2FtMYIi+sK16C7rCOoMXgr1vT +bGqQ9+i1VZimf31YVCHXBDvebeXjY5pII2Rw537zQNrWUvfRpZhr4ofX4jfBJw= =Qd2V -END PGP SIGNATURE- - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org -- Alberto Simões - 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] Yet again, FOP complaining of the generated fo file
On Tue, Apr 3, 2012 at 9:24 PM, Bob Stayton b...@sagehill.net wrote: I was still testing, but I just commited it. I'm not sure if dbfo-need will work properly in FOP 1, but at least it won't fail. Sorry for the push. I am working with FOP svn, not sure if it handles that. But for now I just want it not to fail. Thank you Alberto Bob Stayton Sagehill Enterprises b...@sagehill.net - Original Message - From: Alberto Simões hashas...@gmail.com To: Bob Stayton b...@sagehill.net Cc: David Cramer da...@thingbag.net; docbook-apps@lists.oasis-open.org Sent: Tuesday, April 03, 2012 12:52 PM Subject: Re: [docbook-apps] Yet again, FOP complaining of the generated fo file Bob, did you commit? :) http://docbook.svn.sourceforge.net/viewvc/docbook/trunk/xsl/?view=log doesn't list any changes for today. Thanks On Tue, Apr 3, 2012 at 8:08 PM, Bob Stayton b...@sagehill.net wrote: Oh, if you want to test with FOP1 and stylesheet version 1.76.1 or snapshot, you need to edit the template for dbfo need in fo/pi.xsl, because it has an xsl:when clause to skip any need PIs when fop1.extensions != 0. Bob Stayton Sagehill Enterprises b...@sagehill.net - Original Message - From: David Cramer da...@thingbag.net To: docbook-apps@lists.oasis-open.org Sent: Tuesday, April 03, 2012 11:17 AM Subject: Re: [docbook-apps] Yet again, FOP complaining of the generated fo file -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 04/03/2012 12:13 PM, Alberto Simões wrote: ?dbfo-need height=”2in” ? I was under the impression that the dbfo-need doesn't work with fop (though I don't know if it causes harm). If it works now, I'd be interested in using it. Thanks, David -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEcBAEBAgAGBQJPez69AAoJEMHeSXG7afUhR1wH/RcnZzlTqBSic7QPIlurIXGE RDywDamce+mq90wT26NQs8YKVJO+auxiqzBTyGbHGwzu+H5/BGs9sm3Mi3b9LbEC J04f+tptQu8qFmk8rMhQQ/nItAI9e3e432M9k+gQl9b2NY0ZqEkTU4pqcrfShmcg 5lV7Oh49FOIZmS4anYORg+hxT9uYatY1TTP7SnysyzEuKJznJ4ExByzNQmtFlVdU S88pNlJR+27d1YzdD9oiwz1O+fZ03NCuPXwxr2P2FtMYIi+sK16C7rCOoMXgr1vT +bGqQ9+i1VZimf31YVCHXBDvebeXjY5pII2Rw537zQNrWUvfRpZhr4ofX4jfBJw= =Qd2V -END PGP SIGNATURE- - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org -- Alberto Simões - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org -- Alberto Simões - 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] Are docbook xsl up-to-date?
Dear All, I am kind of new to this world of docbook. I managed to convert a validated docbook XML into a FO file. But then, fop complains that the FO file is not valid: SEVERE: Exception javax.xml.transform.TransformerException: org.apache.fop.fo.ValidationException: fo:inline is not a valid child of fo:block! (See position 1870:716) Any idea what am I doing wrong? Or are the XSL needing some fix? Thank you Alberto -- Alberto Simões - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org