From 31f95a7fafb8d2f9b1d93da99f0a37261cdb69ab Mon Sep 17 00:00:00 2001 From: Julian Smart Date: Sat, 25 Aug 2012 18:03:23 +0000 Subject: [PATCH] Fixed a problem with text effects flag always being set on dialog exit git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72376 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/richtext/richtextfontpage.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/richtext/richtextfontpage.cpp b/src/richtext/richtextfontpage.cpp index 89c9f1e023..32427ab2ba 100644 --- a/src/richtext/richtextfontpage.cpp +++ b/src/richtext/richtextfontpage.cpp @@ -475,6 +475,9 @@ bool wxRichTextFontPage::TransferDataFromWindow() attr->SetTextEffects(attr->GetTextEffects() & ~(wxTEXT_ATTR_EFFECT_SUBSCRIPT|wxTEXT_ATTR_EFFECT_SUPERSCRIPT) ); } + if (attr->GetTextEffectFlags() == 0) + attr->SetFlags(attr->GetFlags() & ~wxTEXT_ATTR_EFFECTS); + return true; } @@ -1044,7 +1047,7 @@ void wxRichTextFontPage::OnIdle( wxIdleEvent& WXUNUSED(event) ) { if (!m_sizeUnitsCtrl) return; - + if (m_sizeUnitsCtrl->GetSelection() == 1 && m_sizeListBox->IsShown()) { m_fontListBoxParent->Show(m_sizeListBox, false);