]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/text/text.cpp
use MSWAlwaysDrawBg() to fix the problem with black background; rewrote/cleaned up...
[wxWidgets.git] / samples / text / text.cpp
index 2b6f3701e44d50ba42d622497d2fbd788a55820c..c5f32c8d0e7d3befdfdf8e164b01efc522766c9d 100644 (file)
@@ -1696,6 +1696,21 @@ void RichTextFrame::OnIdle(wxIdleEvent& WXUNUSED(event))
                 (const wxChar*) facename,
                 attr.GetTextColour().Red(), attr.GetTextColour().Green(), attr.GetTextColour().Blue(),
                 (const wxChar*) alignment);
+
+            if (attr.HasFont())
+            {
+                if (attr.GetFont().GetWeight() == wxBOLD)
+                    msg += wxT(" BOLD");
+                else if (attr.GetFont().GetWeight() == wxNORMAL)
+                    msg += wxT(" NORMAL");
+
+                if (attr.GetFont().GetStyle() == wxITALIC)
+                    msg += wxT(" ITALIC");
+
+                if (attr.GetFont().GetUnderlined())
+                    msg += wxT(" UNDERLINED");
+            }
+
             SetStatusText(msg);
         }
 #endif // wxUSE_STATUSBAR