From 7b1b86a1c9a07d1a81b0fcf56c2f6f5ada312978 Mon Sep 17 00:00:00 2001 From: Lee Thomason Date: Mon, 4 Jun 2012 17:01:38 -0700 Subject: [PATCH] removed confusing getter/setter. cleaned up comments. --- tinyxml2.h | 8 -------- xmltest.cpp | 14 ++++++++++---- 2 files changed, 10 insertions(+), 12 deletions(-) diff --git a/tinyxml2.h b/tinyxml2.h index e2e3e11..93b3802 100644 --- a/tinyxml2.h +++ b/tinyxml2.h @@ -1378,14 +1378,6 @@ public: */ const int CStrSize()const{ return buffer.Size(); } - /** - Set printer to compact mode, for printing without '\n' and space, - let output file smaller. - */ - void SetCompactMode( bool on ){ compactMode = on; } - bool IsCompactMode()const{ return compactMode; }; - - private: void SealElement(); void PrintSpace( int depth ); diff --git a/xmltest.cpp b/xmltest.cpp index 74b2f98..c9fbf79 100644 --- a/xmltest.cpp +++ b/xmltest.cpp @@ -248,10 +248,16 @@ int main( int /*argc*/, const char ** /*argv*/ ) doc->Print(); - XMLPrinter streamer; - doc->Print( &streamer ); - printf( "%s", streamer.CStr() ); - + { + XMLPrinter streamer; + doc->Print( &streamer ); + printf( "%s", streamer.CStr() ); + } + { + XMLPrinter streamer( 0, true ); + doc->Print( &streamer ); + XMLTest( "Compact mode", "", streamer.CStr(), false ); + } delete doc; } {