X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4fdc2c5f2a4dd7f1394e374095b1cd3a34dfaa1b..dc735b4085a71ba204bca6a61bd35e99d1e13ea6:/src/richtext/richtexthtml.cpp diff --git a/src/richtext/richtexthtml.cpp b/src/richtext/richtexthtml.cpp index 6079da35c5..3244486e09 100644 --- a/src/richtext/richtexthtml.cpp +++ b/src/richtext/richtexthtml.cpp @@ -322,7 +322,7 @@ void wxRichTextHTMLHandler::BeginParagraphFormatting(const wxTextAttr& WXUNUSED( str << wxT(">"); // TODO: convert to pixels - int indentPixels = indentLeftMM*10/4; + int indentPixels = static_cast(indentLeftMM*10/4); if ((GetFlags() & wxRICHTEXT_HANDLER_USE_CSS) == 0) { @@ -331,8 +331,6 @@ void wxRichTextHTMLHandler::BeginParagraphFormatting(const wxTextAttr& WXUNUSED( m_inTable = true; } - OutputFont(thisStyle, str); - if (((GetFlags() & wxRICHTEXT_HANDLER_USE_CSS) == 0) && (thisStyle.GetLeftSubIndent() < 0)) { str << SymbolicIndent( - thisStyle.GetLeftSubIndent()); @@ -366,16 +364,17 @@ void wxRichTextHTMLHandler::BeginParagraphFormatting(const wxTextAttr& WXUNUSED( str << wxT(">"); } + OutputFont(thisStyle, str); } /// End paragraph formatting void wxRichTextHTMLHandler::EndParagraphFormatting(const wxTextAttr& WXUNUSED(currentStyle), const wxTextAttr& thisStyle, wxTextOutputStream& stream) { + if (thisStyle.HasFont()) + stream << wxT(""); + if (m_inTable) { - if (thisStyle.HasFont()) - stream << wxT(""); - stream << wxT("

\n"); m_inTable = false; }