Virtual destructor as for any base class.
-\membersection{wxRendererNative::DrawCheckButton}\label{wxrenderernativedrawcheckbutton}
+\membersection{wxRendererNative::DrawCheckBox}\label{wxrenderernativedrawcheckbox}
-\func{void}{DrawCheckButton}{\param{wxWindow *}{win}, \param{wxDC\& }{dc}, \param{const wxRect\& }{rect}, \param{int }{flags}}
+\func{void}{DrawCheckBox}{\param{wxWindow *}{win}, \param{wxDC\& }{dc}, \param{const wxRect\& }{rect}, \param{int }{flags}}
Draw a check box (used by wxDataViewCtrl).
renderer (the global renderer must always exist).
Return the previous renderer used with Set() or {\tt NULL} if none.
-
// draw check button
//
// flags may use wxCONTROL_CHECKED, wxCONTROL_UNDETERMINED and wxCONTROL_CURRENT
- virtual void DrawCheckButton(wxWindow *win,
- wxDC& dc,
- const wxRect& rect,
- int flags = 0) = 0;
+ virtual void DrawCheckBox(wxWindow *win,
+ wxDC& dc,
+ const wxRect& rect,
+ int flags = 0) = 0;
// draw blank button
//
int flags = 0)
{ m_rendererNative.DrawDropArrow(win, dc, rect, flags); }
- virtual void DrawCheckButton(wxWindow *win,
- wxDC& dc,
- const wxRect& rect,
- int flags = 0 )
- { m_rendererNative.DrawCheckButton( win, dc, rect, flags ); }
+ virtual void DrawCheckBox(wxWindow *win,
+ wxDC& dc,
+ const wxRect& rect,
+ int flags = 0 )
+ { m_rendererNative.DrawCheckBox( win, dc, rect, flags ); }
virtual void DrawPushButton(wxWindow *win,
wxDC& dc,
#endif // !wxHAS_NATIVE_RENDERER
#endif // _WX_RENDERER_H_
-
if (GetMode() != wxDATAVIEW_CELL_ACTIVATABLE)
flags |= wxCONTROL_DISABLED;
- wxRendererNative::Get().DrawCheckButton(
+ wxRendererNative::Get().DrawCheckBox(
GetOwner()->GetOwner(),
*dc,
rect,
const wxRect& rect,
int flags = 0);
- virtual void DrawCheckButton(wxWindow *win,
- wxDC& dc,
- const wxRect& rect,
- int flags = 0);
+ virtual void DrawCheckBox(wxWindow *win,
+ wxDC& dc,
+ const wxRect& rect,
+ int flags = 0);
virtual void DrawPushButton(wxWindow *win,
wxDC& dc,
}
void
-wxRendererGeneric::DrawCheckButton(wxWindow *WXUNUSED(win),
- wxDC& dc,
- const wxRect& rect,
- int flags)
+wxRendererGeneric::DrawCheckBox(wxWindow *WXUNUSED(win),
+ wxDC& dc,
+ const wxRect& rect,
+ int flags)
{
dc.SetPen(*(flags & wxCONTROL_DISABLED ? wxGREY_PEN : wxBLACK_PEN));
dc.SetBrush( *wxTRANSPARENT_BRUSH );
///////////////////////////////////////////////////////////////////////////////
-// Name: gtk/renderer.cpp
+// Name: src/gtk/renderer.cpp
// Purpose: implementation of wxRendererNative for wxGTK
// Author: Vadim Zeitlin
// Modified by:
const wxRect& rect,
int flags = 0);
- virtual void DrawCheckButton(wxWindow *win,
- wxDC& dc,
- const wxRect& rect,
- int flags = 0);
+ virtual void DrawCheckBox(wxWindow *win,
+ wxDC& dc,
+ const wxRect& rect,
+ int flags = 0);
virtual void DrawPushButton(wxWindow *win,
wxDC& dc,
wxDC& dc,
const wxRect& rect,
int flags = 0);
-
+
virtual wxSplitterRenderParams GetSplitterParams(const wxWindow *win);
private:
// used by DrawTreeItemButton()
static GtkWidget *GetTreeWidget();
-
- // used by DrawCheckButton()
+
+ // used by DrawCheckBox()
static GtkWidget *GetCheckButtonWidget();
};
}
void
-wxRendererGTK::DrawCheckButton(wxWindow *win,
- wxDC& dc,
- const wxRect& rect,
- int flags )
+wxRendererGTK::DrawCheckBox(wxWindow *win,
+ wxDC& dc,
+ const wxRect& rect,
+ int flags )
{
GtkWidget *button = GetCheckButtonWidget();
// for reason why we do this, see DrawDropArrow
wxWindowDC& wdc = (wxWindowDC&)dc;
wxASSERT ( wdc.IsKindOf(CLASSINFO(wxWindowDC)) );
-
+
GtkStateType state;
if ( flags & wxCONTROL_PRESSED )
state = GTK_STATE_PRELIGHT;
else
state = GTK_STATE_NORMAL;
-
+
gtk_paint_check
(
button->style,
wxASSERT ( wdc.IsKindOf(CLASSINFO(wxWindowDC)) );
GtkStateType state;
- if (flags & wxCONTROL_SELECTED)
+ if (flags & wxCONTROL_SELECTED)
{
if (flags & wxCONTROL_FOCUSED)
- state = GTK_STATE_SELECTED;
+ state = GTK_STATE_SELECTED;
else
- state = GTK_STATE_INSENSITIVE;
+ state = GTK_STATE_INSENSITIVE;
gtk_paint_flat_box( win->m_wxwindow->style,
GTK_PIZZA(win->m_wxwindow)->bin_window,
rect.width,
rect.height );
}
-
+
if (flags & wxCONTROL_CURRENT)
{
dc.SetPen( *wxBLACK_PEN );
dc.DrawRectangle( rect );
}
}
-
///////////////////////////////////////////////////////////////////////////////
-// Name: msw/renderer.cpp
+// Name: src/msw/renderer.cpp
// Purpose: implementation of wxRendererNative for Windows
// Author: Vadim Zeitlin
// Modified by:
wxDC& dc,
const wxRect& rect,
int flags = 0);
- virtual void DrawCheckButton(wxWindow *win,
- wxDC& dc,
- const wxRect& rect,
- int flags = 0);
+ virtual void DrawCheckBox(wxWindow *win,
+ wxDC& dc,
+ const wxRect& rect,
+ int flags = 0);
virtual void DrawPushButton(wxWindow *win,
wxDC& dc,
}
void
-wxRendererXP::DrawCheckButton(wxWindow *win,
- wxDC& dc,
- const wxRect& rect,
- int flags)
+wxRendererXP::DrawCheckBox(wxWindow *win,
+ wxDC& dc,
+ const wxRect& rect,
+ int flags)
{
wxUxThemeHandle hTheme(win, L"BUTTON");
if ( !hTheme )
{
- m_rendererNative.DrawCheckButton(win, dc, rect, flags);
+ m_rendererNative.DrawCheckBox(win, dc, rect, flags);
return;
}
}
#endif // wxUSE_UXTHEME
-