Summary: | Relaxed validation NYI for fo:table-cells | ||
---|---|---|---|
Product: | Fop - Now in Jira | Reporter: | M.H. <mhilpert> |
Component: | fo tree | Assignee: | fop-dev |
Status: | CLOSED FIXED | ||
Severity: | enhancement | ||
Priority: | P2 | ||
Version: | trunk | ||
Target Milestone: | --- | ||
Hardware: | PC | ||
OS: | Windows 2000 |
Description
M.H.
2005-11-02 11:40:54 UTC
<xsl:include> has nothing to do with XSL-FO or FOP, it is specific to XSLT. Generating a Printed Document (PDF or PS) from XML is typically a two step process: XML + XSL -> FO -> PDF FOP is responsible for generating a PDF from FO. For the user's convenience the interface to FOP will take XML + XSL files which FOP passes off to a XSLT processor, e.g. Xalan, which generates the FO file, and passes it via SAX to FOP which generates the PDF. So in order to track down your problem when you have multiple XSL files you will need to first run the XSL Transform part of this process separately using Xalan or similar to generate a large FO file which will have all your xsl:includes pulled in. It should then be easier to find the problem by looking at the FO file. A polite request: problems/questions should be directed to the fop-user mailing list before they are raised as bugs. Thanks Have you seen http://xmlgraphics.apache.org/fop/trunk/upgrading.html ? The upgrade issue you describe is explained in a fairly prominent position on that page. If you mean this: While FOP 0.20.5 allowed you to have empty fo:table-cell elements, the new code will complain about that (unless relaxed validation is enabled) because the specification demands at least one block-level element ((%block;)+, see XSL-FO 1.0, 6.7.10) inside an fo:table-cell element. It still appears after adding "-r" in the fop.bat call ("relaxed validation"). >A polite request: problems/questions should be directed to the fop-user
mailing list before they are raised as bugs. Thanks
This is not a question, but a "request for enhancement". The error message I
posted above is an example. And it is a error message from FOP (as a FOP user,
it doesn't matter if it uses Xalan or similar internally), so I ask if it would
be possible to give some more information in the error message to identify
which source files are concerend.
As I explained the XSL files have nothing to do with FOP, so its impossible for FOP to tell you which file/line number in XSL stylesheet(s) the problem lies at. FOP can only tell you which line in the single FO file the error occurred at. For the record: 1. I agree with Chris that FOP can't be expected to tell you where precisely in which source document the error lies (FOP is ultimately presented with the result of the XSL transform, so all the references to whatever source files you're using is lost at that point) FOP could add location info to the error message, but this makes little sense if the intermediate FO doesn't exist as a physical file. 2. The error message is, IMO, quite self-explanatory (at least for anyone who has had so much as a glance at the XSL-FO Recommendation). It simply means that an fo:table-cell should have 'zero-or- more markers' plus 'one-or-more block-level' descendants (according to the XSL-FO Rec.) 3. The relaxed validation doesn't work yet for this particular case... Either this is an oversight in the docs, or this is still TODO. I'll see if I can commit a fix for this ASAP. OK it's fixed. Please do note that this will only lead to usable results if the cells are really supposed to be empty. Any text-content of the cell will be silently ignored/dropped. On second thought: dropping it silently seemed outright stupid, so added a little warning message batch transition pre-FOP1.0 resolved+fixed bugs to closed+fixed |