Subject: Re: default element construction rule From: Chris Maden <crism@xxxxxxx> Date: Tue, 17 Mar 1998 10:58:53 -0500 |
[Gregg Reynolds] > Paul Prescod wrote: > > > > The default rule is invoked at *every level* in the absenseof anything > > else that matches. > > Yes and no. Below you'll find a very simple dtd, doc instance and > stylesheet. If you experiment with commenting out various lines > you'll find that the only way to fire the H2 element-construction > rule is to include a construction rule for its ancestors, ... or to use the easy way. > **UNLESS** you omit the default-element-construction-rule. There is always a default element construction rule. For elements, it is (process-children), and for data nodes, it's (make character). See clause 12.4.1 (near the bottom of p. 175 if you have the ISO PostScript), the paragraph beginning, "In addition to _construction-rule_s explicitly specified in _style-language-body_s, there is an implicit _default construction-rule_." The trick is to turn off the processing of data so that you only process element children, and then provide an overriding construction rule for what you want. See <URL:http://www.mulberrytech.com/dsssl/dssslist/archive/1947.html> for how I do this. -Chris -- <!NOTATION SGML.Geek PUBLIC "-//Anonymous//NOTATION SGML Geek//EN"> <!ENTITY crism PUBLIC "-//O'Reilly//NONSGML Christopher R. Maden//EN" "<URL>http://www.oreilly.com/people/staff/crism/ <TEL>+1.617.499.7487 <USMAIL>90 Sherman Street, Cambridge, MA 02140 USA" NDATA SGML.Geek> DSSSList info and archive: http://www.mulberrytech.com/dsssl/dssslist
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: default element construction ru, Gregg Reynolds | Thread | Required files for Jade, Chuck Darney |
Re: default element construction ru, Gregg Reynolds | Date | Re: Convert DTD to IDL ?, Gavin Nicol |
Month |