Menu

#5 "pretty serializing" is bad

open
nobody
None
5
2002-10-24
2002-10-24
No

The "pretty serializing" feature of Pollo is causing a
bit of harm to certain files; namely, the way it
indents element's text bodies causes bad output in some
applications given the formatted XML file as input; all
spaces in those elements are significant to the
application(s) (with good reason in many cases).

I might suggest, if making it an option as mentioned on
the website is too much trouble atm, to (in the case of
multi-line text bodies in elements) to not indent the
lines any more than the author asked for, and to
remember/respect the indentation when reading in the file.

i.e., instead of outputting w/ indentation:
<tag>Line 1
Line 2
Line 3</tag>
output the lines without:
<tag>Line1
Line 2
Line 3</tag>
(Hopefully this bug system shows that formatting
correctly...)

Discussion

  • Sean Middleditch

    Logged In: YES
    user_id=26193

    Erg, and no, this bug system did *not* do the formatting
    correctly - in both example, the <tag>... line was indented.
    In the first example, the subsequent lines were indented
    (as they shouldn't be) and the second example they were not
    indented. It's uglier, but doesn't confuse applications
    that treat the indentation as intentional whitespace.

     
  • Sean Middleditch

    • summary: "pretty serializing" is bad --> "pretty serializing" is bad
     

Log in to post a comment.