Re: XM_FORMATTER
"Franck Arnaud" <[email protected]>
| Newsgroups | gmane.comp.lang.eiffel.gobo.general |
|---|---|
| Message-ID | <[email protected]> |
(I was a bit in a hurry so forgot a few points:) > If you do need proper xmlns support you need to put > the XM_XMLNS_GENERATOR filter BEFORE the pretty > printing. In Gobo CVS. It's missing from Gobo release, and there's probably no non-broken way to output correct xmlns from a tree in 3.3. Also using a tree may make sense if you do use the tree for something else than printing an event stream. As for the xml declaration, I can't check at the moment (I'm away from my PC, and sourceforge's CVS browser is broken) but it might be missing at the moment, which may actually make (some) sense because: - the printer filter controls the encoding and always uses the utf8 default encoding (because it gets encoding-neutral strings as input) - the version is assumed to be 1.0 (it might be that a valid event stream could only be printable as 1.1, e.g. if it contains some control chars, but that's not dealt with currently at all). So no declaration is valid. Also using the declared encoding from the input's declaration event, which just reflects the input, but not the parsed state or output, would be incorrect. It would probably be more correct to output a declaration with the version, because this is preferred to no declaration (to clearly identify XML docs) and when 1.1 is supported deal with it, maybe an option, maybe triggered by the declaration event. Also we could allow various encodings on output although that may not be very useful. If you do want an xml declaration now, you can easily have one with any Gobo version by extending the pretty print filter (inherit and redefine on_start or the declaration event). ------------------------ Yahoo! Groups Sponsor --------------------~--> Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar. Now with Pop-Up Blocker. Get it for free! http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/saFolB/TM --------------------------------------------------------------------~-> To Post a message, send it to: [email protected] To Unsubscribe, send a blank message to: [email protected] Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/gobo-eiffel/ <*> 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/