| 1845 | |
| 1846 | |
| 1847 | bool TiXmlPrinter::Visit( const TiXmlText& text ) |
| 1848 | { |
| 1849 | if ( text.CDATA() ) |
| 1850 | { |
| 1851 | DoIndent(); |
| 1852 | buffer += "<![CDATA["; |
| 1853 | buffer += text.Value(); |
| 1854 | buffer += "]]>"; |
| 1855 | DoLineBreak(); |
| 1856 | } |
| 1857 | else if ( simpleTextPrint ) |
| 1858 | { |
| 1859 | TIXML_STRING str; |
| 1860 | TiXmlBase::EncodeString( text.ValueTStr(), &str ); |
| 1861 | buffer += str; |
| 1862 | } |
| 1863 | else |
| 1864 | { |
| 1865 | DoIndent(); |
| 1866 | TIXML_STRING str; |
| 1867 | TiXmlBase::EncodeString( text.ValueTStr(), &str ); |
| 1868 | buffer += str; |
| 1869 | DoLineBreak(); |
| 1870 | } |
| 1871 | return true; |
| 1872 | } |
| 1873 | |
| 1874 | |
| 1875 | bool TiXmlPrinter::Visit( const TiXmlDeclaration& declaration ) |