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 Karen Lease <kl...@club-internet.fr> on 2000/07/18 23:00:09 UTC

property handling

Hi all,

Recently I saw a message which mentioned that one of you was planning on
doing some work on properties (Arved? Fotis?). In any case, I too have
been devoting some time to seeing how we can support all the legal
values for the properties which we support.

There are several aspects.

1. Handling the "compound properties", things like space-before.optimum,
space-before.minimum, etc. I think these should be treated as a single
property and not separate ones.

2. Some properties can use relative units ("em", relative to current
fontsize). These are sort of handled in Length, but it's not complete.

3. Some kinds of property values can't be calculated until layout is
started. The use of percentage values for Length-type properties is a
good example.

4. Handling keyword values for properties whose datatype is not an
enumeration. I mean things like "border-start-width=thin" for example,
which is just an implementation-dependent shorthand for something like
"border-start-width=.5pt". Color properties are another good example,
where "red" really means some RGB value. Our property system currently
doesn't handle these. Either a property is a pure enumeration, like
text-align, or some datatype like Length.

5. Some keywords involve computation. Something like font-size="smaller"
is relative to the current (inherited) value of font-size, but involves
an implementation-dependent computation of what the next "reasonable"
smaller size is.

6. Some properties have "function" type values. For example color type
properties can either be a "standard" color name or an rgb(r,g,b)
function or an icc-color function.

I'm working on:
1. extending properties.xml to store more information
2. rewriting properties.xsl to use this information
3. Automatically extracting at least part of the keyword/datatype
information from Annex C in the XSL Draft (using XSLT of course).

I also think we need some more datatypes to handle the compound
properties. I see Keep (keep values for different areas), LengthRange (a
set of minimum, optimum, and maximum Length values), and Space (like
LengthRange but with precedence and conditionality values).

Best regards,
Karen