-#if FUTURE_WXWIN_COMPATIBILITY_3_0
- wxDEPRECATED_FUTURE( void SetStyle(int style) )
- { SetStyle((wxPenStyle)style); }
-#endif
+ // Convenient helpers for testing whether the pen is a transparent one:
+ // unlike GetStyle() == wxPENSTYLE_TRANSPARENT, they work correctly even if
+ // the pen is invalid (they both return false in this case).
+ bool IsTransparent() const
+ {
+ return IsOk() && GetStyle() == wxPENSTYLE_TRANSPARENT;
+ }
+
+ bool IsNonTransparent() const
+ {
+ return IsOk() && GetStyle() != wxPENSTYLE_TRANSPARENT;
+ }