X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/57f59026216c2ea4ff8c080c7301292dcb69001b..3d2b9c202d215ec220a7b2d62b28768ec7f40e44:/src/html/m_pre.cpp diff --git a/src/html/m_pre.cpp b/src/html/m_pre.cpp index f4999ee76b..b7f283a224 100644 --- a/src/html/m_pre.cpp +++ b/src/html/m_pre.cpp @@ -140,10 +140,14 @@ TAG_HANDLER_BEGIN(PRE, "PRE") { wxString cit; wxEncodingConverter *encconv = m_WParser -> GetEncodingConverter(); - cit = m_WParser -> GetSource() -> Mid(tag.GetBeginPos(), tag.GetEndPos1() - tag.GetBeginPos()); - c -> InsertCell(new wxHtmlPRECell( - encconv ? encconv -> Convert(cit) : cit, - *(m_WParser -> GetDC()))); + cit = m_WParser -> GetSource() -> Mid(tag.GetBeginPos(), + tag.GetEndPos1() - tag.GetBeginPos()); + if (encconv) + c -> InsertCell(new wxHtmlPRECell(encconv -> Convert(cit), + *(m_WParser -> GetDC()))); + else + c -> InsertCell(new wxHtmlPRECell(cit, + *(m_WParser -> GetDC()))); } m_WParser -> SetFontUnderlined(underlined);