On 12/09/05, Eric van der Vlist <[EMAIL PROTECTED]> wrote: > > > > 128 or 60% > > > > How do I specify this in rng please?
> No, you can't write : > > <group> > <data type="positiveInteger"/> > <value>%</value> > </group> > > Each of the "data" or "value" patterns takes a text node (or attribute > value) as a whole... Each must be 'complete' in itself? Is that it? I.e. there is no combination or sequence allowed? > > <attribute name="height"> > <list> > <data type="positiveInteger"/> > <optional> > <value>%</value> > </optional> > </list> > </attribute> > > That would validate "3", "3 %"" but not "3%". Not nice is it:-) > > If you really need to validate "3%", you bust use a token and a pattern > facet: > <attribute name="height"> > <data type="token"> > <param name="pattern">[0-9]+%?</param> > </data> > </attribute> > > the downside is that you loose the semantics of saying that you want a > value followed by a unit... Are you being too fussy Eric? That *seems* to be exactly what I asked for Reading your reply to Robin, The idea of value + unit seems pretty well established. (I'm thinking CSS and XSL-FO) Is this down as a use case in the DSDL world Eric? Thanks for the help regards -- Dave Pawson XSLT XSL-FO FAQ. http://www.dpawson.co.uk ------------------------ Yahoo! Groups Sponsor --------------------~--> Fair play? Video games influencing politics. Click and talk back! http://us.click.yahoo.com/T8sf5C/tzNLAA/TtwFAA/2U_rlB/TM --------------------------------------------------------------------~-> Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/rng-users/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/
