You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by Nikolai Grigoriev <gr...@iitp.ru> on 2000/07/16 10:25:07 UTC

DTD (Was: Re: XSL FO)

Arved Sandstrom wrote:

> I've spent dozens of hours going through the spec and I more than once
> regretted not having a DTD. I understand that such a DTD would be a valuable
> IP, but would you be prepared to gift what you have to the XSL-FO community?
> We would acknowledge your contribution effusively. :-)

Arved,

I have prepared a first version of the DTD for the last draft, and the
decision was taken to make it is publicly available. You can get it from
www.renderx.com/Tests/validator/fo2000.dtd  (plain text) or
www.renderx.com/Tests/validator/fo2000.dtd.html. (HTML, embellished ;-)).

Some notes:

1) The current draft is particularly hard to be validated by a DTD:

     - all properties are made inheritable - either implicitly, or by
       an explicit 'inherit' value;

     - fo:wrapper and other "neutral containers" inhibit the possibility to
       distinguish between inline and block context.

Therefore, this DTD is inevitably weaker then that of the previous draft.

2) The goal of the DTD is practical - to ensure that forthcoming test files have
a correct structure. In some places, I have made it more restrictive than the
draft; this is described in the comments in the body of the DTD.

3) I have adopted a strict content model for fo:simple-page-master - it is
written so in the draft. Most of FOP examples are very liberal in ordering
fo:region-* elements, while the current draft (as well as all previous ones)
prescribes a rigid ordering. I know this is not semantically motivated - without
validation, XEP also works smoothly with regions placed in whatever order.
Unfortunately, I have no other means to check that there be exactly one
fo:region-body and not more than one of every other elements. (Enumerating all
transpositions does not seem a happy idea - when you will be presented an
error message from the validator with such a rule cited, you can hardly guess
what's wrong with your input ;-)).

4) fo:instream-foreign-object is left  EMPTY. Please fill in the SVG part.

5) (disclaimer) I have tested it somehow, but there still may be errors in it.
Please be critical, and send me your opinions and/or bug reports. Comments will
be greatly appreciated.

Best regards,

Nikolai Grigoriev
RenderX






Re: DTD (Was: Re: XSL FO)

Posted by Arved Sandstrom <Ar...@chebucto.ns.ca>.
Hi, Nikolai

I have it. Thanks.

I'll take a serious look at it. You can count on some extensive feedback.

This is important intellectual property, and I applaud your decision to 
release it. If we (FOP) make use of it, we will credit RenderX explicitly.

I agree with you. The XSL spec has always looked like something that makes 
for nightmares when trying to produce a DTD. :-) I can only assume that the 
WG never actually relied on one.

Your points with respect to simple-page-master are well-taken. This is my 
next project.

Regards, Arved

At 12:25 PM 7/16/00 +0400, you wrote:
>Arved Sandstrom wrote:
>
>> I've spent dozens of hours going through the spec and I more than once
>> regretted not having a DTD. I understand that such a DTD would be a
valuable
>> IP, but would you be prepared to gift what you have to the XSL-FO
community?
>> We would acknowledge your contribution effusively. :-)
>
>Arved,
>
>I have prepared a first version of the DTD for the last draft, and the
>decision was taken to make it is publicly available. You can get it from
>www.renderx.com/Tests/validator/fo2000.dtd  (plain text) or
>www.renderx.com/Tests/validator/fo2000.dtd.html. (HTML, embellished ;-)).
>
>Some notes:
>
>1) The current draft is particularly hard to be validated by a DTD:
>
>     - all properties are made inheritable - either implicitly, or by
>       an explicit 'inherit' value;
>
>     - fo:wrapper and other "neutral containers" inhibit the possibility to
>       distinguish between inline and block context.
>
>Therefore, this DTD is inevitably weaker then that of the previous draft.
>
>2) The goal of the DTD is practical - to ensure that forthcoming test
files have
>a correct structure. In some places, I have made it more restrictive than the
>draft; this is described in the comments in the body of the DTD.
>
>3) I have adopted a strict content model for fo:simple-page-master - it is
>written so in the draft. Most of FOP examples are very liberal in ordering
>fo:region-* elements, while the current draft (as well as all previous ones)
>prescribes a rigid ordering. I know this is not semantically motivated -
without
>validation, XEP also works smoothly with regions placed in whatever order.
>Unfortunately, I have no other means to check that there be exactly one
>fo:region-body and not more than one of every other elements. (Enumerating
all
>transpositions does not seem a happy idea - when you will be presented an
>error message from the validator with such a rule cited, you can hardly guess
>what's wrong with your input ;-)).
>
>4) fo:instream-foreign-object is left  EMPTY. Please fill in the SVG part.
>
>5) (disclaimer) I have tested it somehow, but there still may be errors in
it.
>Please be critical, and send me your opinions and/or bug reports. Comments
will
>be greatly appreciated.
>
>Best regards,
>
>Nikolai Grigoriev
>RenderX
>
>
>
>
>
>
Senior Developer
e-plicity.com (www.e-plicity.com)
Halifax, Nova Scotia
"B2B Wireless in Canada's Ocean Playground"