[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: A proposal for simplify XML text editing and subsequent pr

  • From: Philip Fearon <pgfearo@googlemail.com>
  • To: liam@w3.org
  • Date: Sun, 21 Aug 2011 14:30:49 +0100

Re:  A proposal for simplify XML text editing and subsequent pr
On Sun, Aug 21, 2011 at 3:28 AM, Liam R E Quin <liam@w3.org> wrote:

>>  To complement this, editors should have a capability to
>> safely strip such indentation characters when encountered (the reverse
>> of what pretty-print formatters achieve) in external sources.
>
> You can only do that in general with a schema (e.g. a DTD or XSD schema)
> of course.

The indentation characters found in formatted XML, though often
inconsistent (as they often are in examples found online - even in W3C
documents - not a criticism just an observation), can still provide
some useful clues as to the true purpose of leading whitespace
characters.

A crude  example of how patterns in leading whitespace can provide
clues as to its purpose:

....<abc>
......<pre-x>
...Its evident that this block of text should have the
...............whitespace preserved because it's inconsistent
...with previous padding and the XML content
......</pre-x>
...</abc>

Granted, the trimming will never be 100% safe, but I would argue that,
without a schema or configuration settings, its possible to trim
leading whitespace characters much more safely than pretty-print (even
in the leading XML tools) inserts them.


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.