From d1c8e1290bf42b2e7a80e8b04bee2c1aabfd950d Mon Sep 17 00:00:00 2001 From: Julian Smart Date: Fri, 1 Nov 2013 18:07:26 +0000 Subject: [PATCH] Avoid invisible text in style list git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75116 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/richtext/richtextstyles.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/richtext/richtextstyles.cpp b/src/richtext/richtextstyles.cpp index ab98d93d0a..f34d5a1f12 100644 --- a/src/richtext/richtextstyles.cpp +++ b/src/richtext/richtextstyles.cpp @@ -842,7 +842,7 @@ wxString wxRichTextStyleListBox::CreateHTML(wxRichTextStyleDefinition* def) cons if (!attr.GetFontFaceName().IsEmpty()) str << wxT(" face=\"") << attr.GetFontFaceName() << wxT("\""); - if (attr.GetTextColour().IsOk()) + if (attr.GetTextColour().IsOk() && attr.GetTextColour() != attr.GetBackgroundColour() && !(!attr.HasBackgroundColour() && attr.GetTextColour() == *wxWHITE)) str << wxT(" color=\"#") << ColourToHexString(attr.GetTextColour()) << wxT("\""); if (attr.GetBackgroundColour().Ok())