"),
+ left_indent.c_str(), //Document-Wide Left Indent
+ right_indent.c_str()); //Document-Wide Right Indent
+
+ str << wxT(" | ");
+ */
+
+ str << wxT("");
+
+ str << wxString::Format(wxT(""),
+ currentParaStyle.GetFont().GetFaceName().c_str(), Pt_To_Size( currentParaStyle.GetFont().GetPointSize() ),
+ currentParaStyle.GetTextColour().Red(), currentParaStyle.GetTextColour().Green(),
+ currentParaStyle.GetTextColour().Blue());
+
+ //wxString align = GetAlignment( currentParaStyle.GetAlignment() );
+ //str << wxString::Format(wxT(" "), align );
+
+ m_font = false;
+ m_indent = 0;
+ m_list = false;
+
wxRichTextObjectList::compatibility_iterator node = buffer->GetChildren().GetFirst();
while (node)
{
wxRichTextParagraph* para = wxDynamicCast(node->GetData(), wxRichTextParagraph);
wxASSERT (para != NULL);
-
+
if (para)
{
- OutputParagraphFormatting(currentParaStyle, para->GetAttributes(), stream, true);
-
+ OutputParagraphFormatting(currentParaStyle, para->GetAttributes(), stream);
+
wxRichTextObjectList::compatibility_iterator node2 = para->GetChildren().GetFirst();
while (node2)
{
@@ -78,99 +109,481 @@ bool wxRichTextHTMLHandler::DoSaveFile(wxRichTextBuffer *buffer, wxOutputStream&
wxRichTextPlainText* textObj = wxDynamicCast(obj, wxRichTextPlainText);
if (textObj && !textObj->IsEmpty())
{
- OutputCharacterFormatting(currentCharStyle, obj->GetAttributes(), stream, true);
-
+ BeginCharacterFormatting(currentCharStyle, obj->GetAttributes(), stream);
+
str << textObj->GetText();
-
- OutputCharacterFormatting(currentCharStyle, obj->GetAttributes(), stream, false);
+
+ EndCharacterFormatting(currentCharStyle, obj->GetAttributes(), stream);
}
-
+
+ wxRichTextImage* image = wxDynamicCast(obj, wxRichTextImage);
+ if( image && !image->IsEmpty())
+ Image_to_Base64( image, stream );
+
node2 = node2->GetNext();
}
-
- OutputParagraphFormatting(currentParaStyle, para->GetAttributes(), stream, false);
-
- str << wxT(" \n");
+ //OutputParagraphFormatting(currentParaStyle, para->GetAttributes(), stream, false);
}
-
node = node->GetNext();
}
-
- str << wxT("\n");
-
+
+ str << wxT(" |
|