RE: [xml] Formatting output
- From: Sean Middleditch <elanthis awesomeplay com>
- To: Brett Robichaud <brobichaud digimarc com>
- Cc: "'xml gnome org'" <xml gnome org>
- Subject: RE: [xml] Formatting output
- Date: 12 Dec 2002 10:50:02 -0500
It does depend on your application; i was merely pointing out that, in
the event you are editing arbitrary xml, *please* do not
word-wrap/line-break just for the hell of it; it *will* break apps, and
isn't even anything to do with "machine" readble - humans have notions
of what line-breaks, paragraph indentation, spacing, etc. mean as well.
Which is why some XML programs care about it all ;-)
On Thu, 2002-12-12 at 10:45, Brett Robichaud wrote:
I am no xml expert or purist, but to me part of XML's huge benefit is its
human readability. If you take formatting away it becomes simply a computer
protocol not unlike many others. Don't get me wrong, I'm not bashing anyone
here if libXML doesn't support it, but personally I'd love to see it as a
feature.
-Brett-
-----Original Message-----
From: Sean Middleditch [mailto:elanthis awesomeplay com]
Sent: Thursday, December 12, 2002 6:36 AM
To: 'xml gnome org'
Subject: RE: [xml] Formatting output
For what it's worth, line-breaking XML output is *evil*. A
lot of XML editors do this, and thus completely break files
used by various apps; I use several of which, just as the XML
spec states, _all whitespace is significant_. The output
from these programs when using XML files with ****'d up XML
(from the editors w/ line-breaks) is way weird. Making the
apps "trim" spaces/new-lines isn't feasible, either, since
often the author of the files *wants* to insert various
white-space indenting/formatting (even for things as simple
as the fact that there are two spaces after punctuation like
. and !, and only one space after a , or ; or whatnot -
something HTML/Web fails horrible to take into
account..)
On Wed, 2002-12-11 at 17:41, Brett Robichaud wrote:
Hmm, yes I can see it is an interesting problem.
Dissapointing news
but I guess I'm not surprised.
Thanks for the quick reply.
-Brett-
-----Original Message-----
From: Daniel Veillard [mailto:veillard redhat com]
Sent: Wednesday, December 11, 2002 2:40 PM
To: Brett Robichaud
Cc: 'xml gnome org'
Subject: Re: [xml] Formatting output
On Wed, Dec 11, 2002 at 02:36:09PM -0800, Brett Robichaud wrote:
I'm using libXML 2.4.28 on Windows and 2.4.25 on Solaris 8. Can
anyone tell me how I can add a new tag to an existing
document and
have it indent and linebreak correctly?
No. Because "indent and linebreak correctly" is not a
problem which can be solved in the general case. "You know
what indetation you want so add the proper text nodes needed
to make that indentation" is the only correct answer.
Daniel
--
Daniel Veillard | Red Hat Network https://rhn.redhat.com/
veillard redhat com | libxml GNOME XML XSLT toolkit
http://xmlsoft.org/ http://veillard.com/ | Rpmfind RPM
search engine
http://rpmfind.net/ _______________________________________________
xml mailing list, project page http://xmlsoft.org/
xml gnome org
http://mail.gnome.org/mailman/listinfo/xml
--
Sean Middleditch <elanthis awesomeplay com>
AwesomePlay Productions, Inc.
_______________________________________________
xml mailing list, project page http://xmlsoft.org/
xml gnome org http://mail.gnome.org/mailman/listinfo/xml
--
Sean Middleditch <elanthis awesomeplay com>
AwesomePlay Productions, Inc.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]