leethomason/tinyxml2 — pull request #30 by sniperbat (2012-05-28 09:27:03+00:00)
Title: Add compact mode to XMLPrint for printing without '\n' and space

let output file smaller.
usage:
//------------------------------------------------
XMLPrinter printer;
printer->SetCompactMode( true ); //enable compact mode
doc->Print( &printer );
SomeFunction( printer.CStr() );
//------------------------------------------------
or
//------------------------------------------------
//enable at construction
XMLPrinter printer( file, true ); // to file
//XMLPrinter printer( NULL, true ); // to men
doc->Print( &printer );
SomeFunction( printer.CStr() );
//------------------------------------------------

The '\n' and space in Text or Attribute will be kept.