From: Julian Smart Date: Wed, 13 Feb 2008 19:26:41 +0000 (+0000) Subject: Make sure paragraph style is reset before applying a new style X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/f2ab7bf3f881ab42c0935e7248fd9283b95622f6 Make sure paragraph style is reset before applying a new style git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@51764 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/richtext/richtextctrl.cpp b/src/richtext/richtextctrl.cpp index 24860a64ad..bf9a7d4f12 100644 --- a/src/richtext/richtextctrl.cpp +++ b/src/richtext/richtextctrl.cpp @@ -2927,7 +2927,7 @@ bool wxRichTextCtrl::ApplyStyle(wxRichTextStyleDefinition* def) // attributes are applied. wxTextAttr attr(GetStyleSheet() ? def->GetStyleMergedWithBase(GetStyleSheet()) : def->GetStyle()); - int flags = wxRICHTEXT_SETSTYLE_WITH_UNDO|wxRICHTEXT_SETSTYLE_OPTIMIZE; + int flags = wxRICHTEXT_SETSTYLE_WITH_UNDO|wxRICHTEXT_SETSTYLE_OPTIMIZE|wxRICHTEXT_SETSTYLE_RESET; if (def->IsKindOf(CLASSINFO(wxRichTextListStyleDefinition))) {