Article View: adobe.framemaker.sgml
Article #724Re: Making a valid XML DTD out of a more general EDD?
From: Harald E Brandt
Date: Sat, 20 Sep 2008 08:53
Date: Sat, 20 Sep 2008 08:53
31 lines
3212 bytes
3212 bytes
David:
it's virtually impossible to keep the DTD and EDD in sync because many XML
attributes (like table "cols") get mapped to Frame properties (like # of
table columns). So I simply stopped worrying about it ... and keep close
watch on my rules file.
Ok, but things like cols attribute etc are taken care of by read/write rules, right? As long as there are automatic translations via the rules file or xslt, I consider them as still being "in sync". What I feared was manual edits that can be difficult to keep in sync over an extended period of time (years).
Jon's suggestion with conditional text is a semiautomated way (that I think Jon, or someone else mentioned a year ago or so?). It does at least bring out the changes somewhat more explicit. However, I still shudder somewhat when faced with changing things like the following example I showed earlier (and other much more involved constructs):
General rule: �TEXT�, (Para | ListUnordered | ListOrdered)*, (NextBlock1
| (NextBlock2, subblock3*))*
Correct me if I am wrong, but to make it valid in xml, isn't a complete flattening the only way to achieve that? Like this:
General rule: (�TEXT� | Para | ListUnordered | ListOrdered | NextBlock1
| NextBlock2 | subblock3)*
...which I consider a pretty drastic departure from the original! Maybe it's still acceptable and safe if it is used for language translation purposes only, but I shudder somewhat (perhaps unjustified)...
The translation agency normally doesn't change the structure, but sometimes they do, also when given structured fm-files; in those cases, I have to manually fix that. The cases where that happens is when a paragraph starts with a concept/definition, and the translator needs to precede the concept with a small word (corresponding to an article such as 'The') and then inserts that small word before the paragraph boundary, which invalidates the structure. It is hard to know if such mistakes will be more or less common in an xml workflow as compared with an fm workflow.
By far a more elegant way to make a valid DTD from the EDD is to replace the TEXT token by a MyText element, and then create a MyText element that only contains the TEXT token. Would that be a completely general method? If so, it remains to find simple automated ways to achieve that. Is it simple to do in xslt? I guess it is impossible to do it with read/write rules, right?
/Harald
Technical Details
Message-ID:
<59b686a8.4@webcrossing.la2eafNXanI>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news2.google.com!eweka.nl!lightspeed.eweka.nl!194.134.4.77.MISMATCH!news2.euro.net!feeds.phibee-telecom.net!tudelft.nl!txtfeed1.tudelft.nl!news4us.nl!webcrossingReferences:
<59b686a8.-1@webcrossing.la2eafNXanI>Show Full Headers
Complete Article Headers
X-Google-Thread: fcc08,7b6fc3c63283a48a X-Google-Attributes: gidfcc08,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII From: "Harald E Brandt" <adobe@bragit.com> Newsgroups: adobe.framemaker.sgml Subject: Re: Making a valid XML DTD out of a more general EDD? Message-ID: <59b686a8.4@webcrossing.la2eafNXanI> Date: Sat, 20 Sep 2008 01:53:33 -0700 References: <59b686a8.-1@webcrossing.la2eafNXanI> Lines: 45 MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news2.google.com!eweka.nl!lightspeed.eweka.nl!194.134.4.77.MISMATCH!news2.euro.net!feeds.phibee-telecom.net!tudelft.nl!txtfeed1.tudelft.nl!news4us.nl!webcrossing