Subject: Re: Processing a home-brewed FOT From: Richard Light <richard@xxxxxxxxxxxxxxxxx> Date: Tue, 21 Jul 1998 09:52:52 +0100 |
In message <u4swcppcv.fsf@xxxxxxxxxxxxxxxxxxx>, Toby Speight <Toby.Speight@xxxxxxxxxxxxxx> writes > >You ought to be able to feed it into the *front end* of Jade if you're >happy to grind out a stylesheet for the identity transform of FOT. I >don't know why such a stylesheet hasn't been contributed to the Jade >distribution; it's hard to believe that no-one has made one yet. Probably because it's a massive job! As far as I can tell, there will need to be a specific declaration for _each_ characteristic of every flow object type in the FOT DTD. What I've come up with so far deals with one characteristic (quadding) of one flow object type (paragraph). However, this approach might be a useful template for the full thing. It uses a procedure (att-to-symbol) which converts the attribute value to lower case (still needed with the latest Jade?) and thence to a symbol. There would need to be similar procedures to convert attribute values to length-specs, booleans, etc. The advantage of this approach is that it lends itself to writing a scripted conversion of the FOT DTD itself to a series of element construction rules: (define (att-to-symbol attname inherited-value) (if (attribute-string attname (current-node)) (string->symbol (STRING-DOWNCASE (attribute-string attname (current- node)))) inherited-value)) (element paragraph (make paragraph ; ... lots of characteristics, including: quadding: (att-to-symbol "quadding" (inherited-quadding)) ; ... lots more characteristics (process-children))) It should be possible to deduce which conversion is required from the ATTLIST declaration for each characteristic in the DTD. Have I missed something obvious, or should this work? Richard Light. Richard Light SGML/XML and Museum Information Consultancy richard@xxxxxxxxxxxxxxxxx DSSSList info and archive: http://www.mulberrytech.com/dsssl/dssslist
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: Processing a home-brewed FOT, Toby Speight | Thread | Re: Processing a home-brewed FOT, Sean Mc Grath |
Re: list of speakers, Paul Prescod | Date | Re: list of speakers, Brandon Ibach |
Month |