+ if ( m_eraseBgInPaint )
+ {
+ dc.SetBackground(*wxLIGHT_GREY);
+ dc.Clear();
+
+ dc.DrawText("Background erased in OnPaint", 65, 110);
+ }
+ else if ( GetBackgroundStyle() == wxBG_STYLE_PAINT )
+ {
+ dc.SetTextForeground(*wxRED);
+ dc.DrawText("You must enable erasing background in OnPaint to avoid "
+ "display corruption", 65, 110);
+ }
+