Bugs item #1903783, was opened at 2008-02-28 11:07
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=116035&aid=1903783&group_id=16035

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Janne (japalm)
Assigned to: Nobody/Anonymous (nobody)
Summary: Line feeds within XML comments updated incorrectly

Initial Comment:
It seems as pretty printing (dom4j 1.6.1) updates line feeds incorrectly for 
XML comments.

Using the following settings for OutputFormat:
        OutputFormat xmlOutput = OutputFormat.createPrettyPrint();
        xmlOutput.setExpandEmptyElements(false);
        xmlOutput.setIndent(true);
        xmlOutput.setIndent(" ");
        xmlOutput.setIndentSize(2);
        xmlOutput.setLineSeparator(System.getProperty("line.separator"));
        xmlOutput.setNewLineAfterDeclaration(false);
        xmlOutput.setNewLineAfterNTags(0);
        xmlOutput.setNewlines(true);
        xmlOutput.setOmitEncoding(false);
        xmlOutput.setPadText(false);
        xmlOutput.setSuppressDeclaration(false);
        xmlOutput.setTrimText(false);

Applied on an XML file with Windows style line separators, existing XML 
comments are updated to something else ('\n' I belive), leaving the XML-file 
with inconsistent line endings. The rest of the document behaves as expected...

I would have expected everything but CDATA content to be updated with line 
separators as configured...

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=116035&aid=1903783&group_id=16035

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
dom4j-dev mailing list
dom4j-dev@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dom4j-dev

Reply via email to