virtual wxVisualAttributes GetDefaultAttributes() const;
protected:
- virtual void ApplyWidgetStyle(bool forceStyle = false);
- // helper function to ease native widgets wrapping, called by
- // ApplyWidgetStyle -- override this, not ApplyWidgetStyle
- virtual void DoApplyWidgetStyle(GtkRcStyle *style);
-
virtual wxSize DoGetBestSize() const;
void PostCreation(const wxSize& size);
void PostSetLabel();
// Overridden in many GTK widgets who have to handle subwidgets
virtual void ApplyWidgetStyle(bool forceStyle = false);
+
+ // helper function to ease native widgets wrapping, called by
+ // ApplyWidgetStyle -- override this, not ApplyWidgetStyle
+ virtual void DoApplyWidgetStyle(GtkRcStyle *style);
private:
DECLARE_DYNAMIC_CLASS(wxWindowGTK)
virtual wxVisualAttributes GetDefaultAttributes() const;
protected:
- virtual void ApplyWidgetStyle(bool forceStyle = false);
- // helper function to ease native widgets wrapping, called by
- // ApplyWidgetStyle -- override this, not ApplyWidgetStyle
- virtual void DoApplyWidgetStyle(GtkRcStyle *style);
-
virtual wxSize DoGetBestSize() const;
void PostCreation(const wxSize& size);
void PostSetLabel();
// Overridden in many GTK widgets who have to handle subwidgets
virtual void ApplyWidgetStyle(bool forceStyle = false);
+
+ // helper function to ease native widgets wrapping, called by
+ // ApplyWidgetStyle -- override this, not ApplyWidgetStyle
+ virtual void DoApplyWidgetStyle(GtkRcStyle *style);
private:
DECLARE_DYNAMIC_CLASS(wxWindowGTK)
return attr;
}
-void wxControl::ApplyWidgetStyle(bool forceStyle)
-{
- GtkRcStyle *style = CreateWidgetStyle(forceStyle);
- if ( style )
- {
- DoApplyWidgetStyle(style);
- gtk_rc_style_unref(style);
- }
-}
-
-void wxControl::DoApplyWidgetStyle(GtkRcStyle *style)
-{
- gtk_widget_modify_style(m_widget, style);
-}
-
-
#endif // wxUSE_CONTROLS
GtkRcStyle *style = CreateWidgetStyle(forceStyle);
if ( style )
{
- if (m_wxwindow)
- // should we also do m_widget in this case?
- gtk_widget_modify_style(m_wxwindow, style);
- else
- gtk_widget_modify_style(m_widget, style);
+ DoApplyWidgetStyle(style);
gtk_rc_style_unref(style);
}
}
+void wxWindowGTK::DoApplyWidgetStyle(GtkRcStyle *style)
+{
+ if (m_wxwindow)
+ // should we also do m_widget in this case?
+ gtk_widget_modify_style(m_wxwindow, style);
+ else
+ gtk_widget_modify_style(m_widget, style);
+}
+
+
//-----------------------------------------------------------------------------
// Pop-up menu stuff
//-----------------------------------------------------------------------------
return attr;
}
-void wxControl::ApplyWidgetStyle(bool forceStyle)
-{
- GtkRcStyle *style = CreateWidgetStyle(forceStyle);
- if ( style )
- {
- DoApplyWidgetStyle(style);
- gtk_rc_style_unref(style);
- }
-}
-
-void wxControl::DoApplyWidgetStyle(GtkRcStyle *style)
-{
- gtk_widget_modify_style(m_widget, style);
-}
-
-
#endif // wxUSE_CONTROLS
GtkRcStyle *style = CreateWidgetStyle(forceStyle);
if ( style )
{
- if (m_wxwindow)
- // should we also do m_widget in this case?
- gtk_widget_modify_style(m_wxwindow, style);
- else
- gtk_widget_modify_style(m_widget, style);
+ DoApplyWidgetStyle(style);
gtk_rc_style_unref(style);
}
}
+void wxWindowGTK::DoApplyWidgetStyle(GtkRcStyle *style)
+{
+ if (m_wxwindow)
+ // should we also do m_widget in this case?
+ gtk_widget_modify_style(m_wxwindow, style);
+ else
+ gtk_widget_modify_style(m_widget, style);
+}
+
+
//-----------------------------------------------------------------------------
// Pop-up menu stuff
//-----------------------------------------------------------------------------