本文整理汇总了C++中wxDC::DrawSpline方法的典型用法代码示例。如果您正苦于以下问题:C++ wxDC::DrawSpline方法的具体用法?C++ wxDC::DrawSpline怎么用?C++ wxDC::DrawSpline使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类wxDC
的用法示例。
在下文中一共展示了wxDC::DrawSpline方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: OnDraw
// Define the repainting behaviour
void MyCanvas::OnDraw(wxDC& dc)
{
dc.SetFont(*wxSWISS_FONT);
dc.SetPen(*wxGREEN_PEN);
dc.DrawLine(0, 0, 200, 200);
dc.DrawLine(200, 0, 0, 200);
dc.SetBrush(*wxCYAN_BRUSH);
dc.SetPen(*wxRED_PEN);
dc.DrawRectangle(100, 100, 100, 50);
dc.DrawRoundedRectangle(150, 150, 100, 50, 20);
dc.DrawEllipse(250, 250, 100, 50);
#if wxUSE_SPLINES
dc.DrawSpline(50, 200, 50, 100, 200, 10);
#endif // wxUSE_SPLINES
dc.DrawLine(50, 230, 200, 230);
dc.DrawText(wxT("This is a test string"), 50, 230);
wxPoint points[3];
points[0].x = 200; points[0].y = 300;
points[1].x = 100; points[1].y = 400;
points[2].x = 300; points[2].y = 400;
dc.DrawPolygon(3, points);
}
示例2: Draw
void MyApp::Draw(wxDC&dc)
{
// This routine just draws a bunch of random stuff on the screen so that we
// can check that different types of object are being drawn consistently
// between the screen image, the print preview image (at various zoom
// levels), and the printed page.
dc.SetBackground(*wxWHITE_BRUSH);
// dc.Clear();
dc.SetFont(m_testFont);
// dc.SetBackgroundMode(wxTRANSPARENT);
dc.SetPen(*wxBLACK_PEN);
dc.SetBrush(*wxLIGHT_GREY_BRUSH);
dc.DrawRectangle(0, 0, 230, 350);
dc.DrawLine(0, 0, 229, 349);
dc.DrawLine(229, 0, 0, 349);
dc.SetBrush(*wxTRANSPARENT_BRUSH);
dc.SetBrush(*wxCYAN_BRUSH);
dc.SetPen(*wxRED_PEN);
dc.DrawRoundedRectangle(0, 20, 200, 80, 20);
dc.DrawText( wxT("Rectangle 200 by 80"), 40, 40);
dc.SetPen( wxPen(*wxBLACK, 0, wxPENSTYLE_DOT_DASH) );
dc.DrawEllipse(50, 140, 100, 50);
dc.SetPen(*wxRED_PEN);
dc.DrawText( wxT("Test message: this is in 10 point text"), 10, 180);
#if wxUSE_UNICODE
const char *test = "Hebrew שלום -- Japanese (日本語)";
wxString tmp = wxConvUTF8.cMB2WC( test );
dc.DrawText( tmp, 10, 200 );
#endif
wxPoint points[5];
points[0].x = 0;
points[0].y = 0;
points[1].x = 20;
points[1].y = 0;
points[2].x = 20;
points[2].y = 20;
points[3].x = 10;
points[3].y = 20;
points[4].x = 10;
points[4].y = -20;
dc.DrawPolygon( 5, points, 20, 250, wxODDEVEN_RULE );
dc.DrawPolygon( 5, points, 50, 250, wxWINDING_RULE );
dc.DrawEllipticArc( 80, 250, 60, 30, 0.0, 270.0 );
points[0].x = 150;
points[0].y = 250;
points[1].x = 180;
points[1].y = 250;
points[2].x = 180;
points[2].y = 220;
points[3].x = 200;
points[3].y = 220;
dc.DrawSpline( 4, points );
dc.DrawArc( 20,10, 10,10, 25,40 );
wxString str;
int i = 0;
str.Printf( wxT("---- Text at angle %d ----"), i );
dc.DrawRotatedText( str, 100, 300, i );
i = m_angle;
str.Printf( wxT("---- Text at angle %d ----"), i );
dc.DrawRotatedText( str, 100, 300, i );
wxIcon my_icon = wxICON(sample);
dc.DrawIcon( my_icon, 100, 100);
if (m_bitmap.IsOk())
dc.DrawBitmap( m_bitmap, 10, 10 );
#if wxUSE_GRAPHICS_CONTEXT
wxGraphicsContext *gc = NULL;
wxPrinterDC *printer_dc = wxDynamicCast( &dc, wxPrinterDC );
if (printer_dc)
gc = wxGraphicsContext::Create( *printer_dc );
wxWindowDC *window_dc = wxDynamicCast( &dc, wxWindowDC );
if (window_dc)
gc = wxGraphicsContext::Create( *window_dc );
#ifdef __WXMSW__
wxEnhMetaFileDC *emf_dc = wxDynamicCast( &dc, wxEnhMetaFileDC );
if (emf_dc)
gc = wxGraphicsContext::Create( *emf_dc );
#endif
//.........这里部分代码省略.........
示例3: OnDraw
// Define the repainting behaviour
void MyCanvas::OnDraw(wxDC& dc)
{
// vars to use ...
#if wxUSE_STATUSBAR
wxString s;
#endif // wxUSE_STATUSBAR
wxPen wP;
wxBrush wB;
wxPoint points[6];
wxColour wC;
wxFont wF;
dc.SetFont(*wxSWISS_FONT);
dc.SetPen(*wxGREEN_PEN);
switch (m_index)
{
default:
case 0:
// draw lines to make a cross
dc.DrawLine(0, 0, 200, 200);
dc.DrawLine(200, 0, 0, 200);
// draw point colored line and spline
wP = *wxCYAN_PEN;
wP.SetWidth(3);
dc.SetPen(wP);
dc.DrawPoint (25,15);
dc.DrawLine(50, 30, 200, 30);
dc.DrawSpline(50, 200, 50, 100, 200, 10);
#if wxUSE_STATUSBAR
s = wxT("Green Cross, Cyan Line and spline");
#endif // wxUSE_STATUSBAR
break;
case 1:
// draw standard shapes
dc.SetBrush(*wxCYAN_BRUSH);
dc.SetPen(*wxRED_PEN);
dc.DrawRectangle(10, 10, 100, 70);
wB = wxBrush (wxT("DARK ORCHID"), wxBRUSHSTYLE_TRANSPARENT);
dc.SetBrush (wB);
dc.DrawRoundedRectangle(50, 50, 100, 70, 20);
dc.SetBrush (wxBrush(wxT("GOLDENROD")) );
dc.DrawEllipse(100, 100, 100, 50);
points[0].x = 100; points[0].y = 200;
points[1].x = 70; points[1].y = 260;
points[2].x = 160; points[2].y = 230;
points[3].x = 40; points[3].y = 230;
points[4].x = 130; points[4].y = 260;
points[5].x = 100; points[5].y = 200;
dc.DrawPolygon(5, points);
dc.DrawLines (6, points, 160);
#if wxUSE_STATUSBAR
s = wxT("Blue rectangle, red edge, clear rounded rectangle, gold ellipse, gold and clear stars");
#endif // wxUSE_STATUSBAR
break;
case 2:
// draw text in Arial or similar font
dc.DrawLine(50,25,50,35);
dc.DrawLine(45,30,55,30);
dc.DrawText(wxT("This is a Swiss-style string"), 50, 30);
wC = dc.GetTextForeground();
dc.SetTextForeground (wxT("FIREBRICK"));
// no effect in msw ??
dc.SetTextBackground (wxT("WHEAT"));
dc.DrawText(wxT("This is a Red string"), 50, 200);
dc.DrawRotatedText(wxT("This is a 45 deg string"), 50, 200, 45);
dc.DrawRotatedText(wxT("This is a 90 deg string"), 50, 200, 90);
wF = wxFont ( 18, wxROMAN, wxITALIC, wxBOLD, false, wxT("Times New Roman"));
dc.SetFont(wF);
dc.SetTextForeground (wC);
dc.DrawText(wxT("This is a Times-style string"), 50, 60);
#if wxUSE_STATUSBAR
s = wxT("Swiss, Times text; red text, rotated and colored orange");
#endif // wxUSE_STATUSBAR
break;
case 3 :
// four arcs start and end points, center
dc.SetBrush(*wxGREEN_BRUSH);
dc.DrawArc ( 200,300, 370,230, 300,300 );
dc.SetBrush(*wxBLUE_BRUSH);
dc.DrawArc ( 270-50, 270-86, 270-86, 270-50, 270,270 );
dc.SetDeviceOrigin(-10,-10);
dc.DrawArc ( 270-50, 270-86, 270-86, 270-50, 270,270 );
dc.SetDeviceOrigin(0,0);
wP.SetColour (wxT("CADET BLUE"));
dc.SetPen(wP);
dc.DrawArc ( 75,125, 110, 40, 75, 75 );
wP.SetColour (wxT("SALMON"));
dc.SetPen(wP);
dc.SetBrush(*wxRED_BRUSH);
//.........这里部分代码省略.........
示例4: draw
//void simple_vector_layer::Draw(wxDC &dc, wxCoord x, wxCoord y, bool transparent, double zoomFactor, double translationX, double translationY, double resolution) const
void simple_vector_layer::draw(wxDC &dc, wxCoord x, wxCoord y, bool transparent) const
{
wxPen pen;
wxBrush brush;
// 2D
pen.SetWidth(m_polygon_border_width);
pen.SetColour(m_polygon_border_color);
pen.SetStyle(m_polygon_border_style);
brush.SetColour(m_polygon_inner_color);
brush.SetStyle(m_polygon_inner_style);
dc.SetPen(pen);
dc.SetBrush(brush);
for (unsigned int i = 0; i < m_circles.size(); i++)
{
wxPoint p = transform().from_local_int(m_circles[i]);
wxCoord r = static_cast<wxCoord>(m_circles[i].radius / transform().zoom_factor());
dc.DrawCircle(p, r);
}
// Ellipses alignees
for (unsigned int i=0;i<m_ellipses.size();++i)
{
wxPoint p = transform().from_local_int(m_ellipses[i]);
wxSize s(
static_cast<wxCoord>(2*m_ellipses[i].a/transform().zoom_factor()),
static_cast<wxCoord>(2*m_ellipses[i].b/transform().zoom_factor())
);
dc.DrawEllipse(p,s);
//dc.DrawEllipticArc(p,s,0.,90.);
//dc.DrawEllipticArcRot(p,s,0.,90.);
}
// Ellipses non alignees
for (unsigned int i=0;i<m_rotatedellipses.size();++i)
{
std::vector<wxPoint> points;
points.reserve( m_rotatedellipses[i].controlPoints.size() );
for (unsigned int j=0;j<m_rotatedellipses[i].controlPoints.size();++j)
points.push_back(transform().from_local_int(m_rotatedellipses[i].controlPoints[j]));
dc.DrawSpline(static_cast<int>(points.size()),&points.front());
}
for (unsigned int i=0;i<m_polygons.size();++i)
{
std::vector<wxPoint> points;
points.reserve( m_polygons[i].size() );
for (unsigned int j=0;j<m_polygons[i].size();++j)
points.push_back(transform().from_local_int(m_polygons[i][j]));
dc.DrawPolygon( static_cast<int>(points.size()) , &(points.front()) );
}
// 1D
pen.SetColour(m_line_color);
pen.SetWidth(m_line_width);
pen.SetStyle(m_line_style);
dc.SetPen(pen);
for (unsigned int i = 0; i < m_arcs.size(); i++)
{
const arc_type &local_tab = m_arcs[i];
for (unsigned int j = 0; j < local_tab.arc_points.size() - 1; ++j)
{
wxPoint p = transform().from_local_int(local_tab.arc_points[j ]);
wxPoint q = transform().from_local_int(local_tab.arc_points[j+1]);
dc.DrawLine(p,q);
}
}
// Splines
for (unsigned int i=0;i<m_splines.size();++i)
{
const spline_type& spline = m_splines[i];
std::vector<wxPoint> points;
unsigned int n = static_cast<int>(spline.size());
for (unsigned int j=0;j<n;++j)
{
wxPoint p = transform().from_local_int(spline[j]);
points.push_back(p);
}
dc.DrawSpline(n,&points.front());
}
// 0D
pen.SetColour(m_point_color);
pen.SetWidth(m_point_width);
dc.SetPen(pen);
for (unsigned int i = 0; i < m_points.size(); i++)
{
wxPoint p = transform().from_local_int(m_points[i]);
//dc.DrawLine(p);
dc.DrawPoint(p);
}
// Text
if(text_visibility())
{
pen.SetColour(m_text_color);
dc.SetPen(pen);
for (unsigned int i = 0; i < m_texts.size(); i++)
{
wxPoint p = transform().from_local_int(m_texts[i].first);
//dc.DrawLine(p);
dc.DrawText(wxString(m_texts[i].second.c_str(),*wxConvCurrent),p);
//.........这里部分代码省略.........
示例5: Draw
void MyFrame::Draw(wxDC& dc)
{
// This routine just draws a bunch of random stuff on the screen so that we
// can check that different types of object are being drawn consistently
// between the screen image, the print preview image (at various zoom
// levels), and the printed page.
dc.SetBackground(*wxWHITE_BRUSH);
dc.Clear();
dc.SetFont(wxGetApp().m_testFont);
dc.SetBackgroundMode(wxTRANSPARENT);
dc.SetPen(*wxBLACK_PEN);
dc.SetBrush(*wxLIGHT_GREY_BRUSH);
// dc.SetBackground(*wxWHITE_BRUSH);
dc.DrawRectangle(0, 0, 230, 350);
dc.DrawLine(0, 0, 229, 349);
dc.DrawLine(229, 0, 0, 349);
dc.SetBrush(*wxTRANSPARENT_BRUSH);
dc.SetBrush(*wxCYAN_BRUSH);
dc.SetPen(*wxRED_PEN);
dc.DrawRoundedRectangle(0, 20, 200, 80, 20);
dc.DrawText( wxT("Rectangle 200 by 80"), 40, 40);
dc.SetPen( wxPen(*wxBLACK,0,wxDOT_DASH) );
dc.DrawEllipse(50, 140, 100, 50);
dc.SetPen(*wxRED_PEN);
dc.DrawText( wxT("Test message: this is in 10 point text"), 10, 180);
#if wxUSE_UNICODE
//char *test = "Hebrew שלום -- Japanese (日本語)";
//wxString tmp = wxConvUTF8.cMB2WC( test );
//dc.DrawText( tmp, 10, 200 );
#endif
wxPoint points[5];
points[0].x = 0;
points[0].y = 0;
points[1].x = 20;
points[1].y = 0;
points[2].x = 20;
points[2].y = 20;
points[3].x = 10;
points[3].y = 20;
points[4].x = 10;
points[4].y = -20;
dc.DrawPolygon( 5, points, 20, 250, wxODDEVEN_RULE );
dc.DrawPolygon( 5, points, 50, 250, wxWINDING_RULE );
dc.DrawEllipticArc( 80, 250, 60, 30, 0.0, 270.0 );
points[0].x = 150;
points[0].y = 250;
points[1].x = 180;
points[1].y = 250;
points[2].x = 180;
points[2].y = 220;
points[3].x = 200;
points[3].y = 220;
dc.DrawSpline( 4, points );
dc.DrawArc( 20,10, 10,10, 25,40 );
wxString str;
int i = 0;
str.Printf( wxT("---- Text at angle %d ----"), i );
dc.DrawRotatedText( str, 100, 300, i );
i = m_angle;
str.Printf( wxT("---- Text at angle %d ----"), i );
dc.DrawRotatedText( str, 100, 300, i );
wxIcon my_icon = wxICON(mondrian) ;
dc.DrawIcon( my_icon, 100, 100);
if (m_bitmap.Ok())
{
dc.DrawBitmap(m_bitmap, 10, 25);
}
if (m_imgUp.Ok())
{
dc.DrawBitmap(m_imgUp, 300, 200);
dc.DrawBitmap(m_imgUp, 300, 250, true);
}
}
示例6: DrawIndividualRawDensityPlot
void RawDataVisualizeFrame::DrawIndividualRawDensityPlot(wxDC& dc){
//PrepareDC(dc);
//SetUpDC(dc);
int w,h;
dc.GetSize(&w, &h);
/* labeledplotAxes myAxes(wxPoint(80,80),
wxPoint(w-30*5,h-30*5),
wxRealPoint(0.0,1000.0),
wxRealPoint(50.0,4000.0),
true);
*/
int min_x = min((int)(pltarea_min_x*(double)w),(int)(160*(double)(dc.GetPPI().x)/(double)72));
int min_y = min((int)(pltarea_min_y*(double)h),(int)(165*(double)(dc.GetPPI().x)/(double)72));
int max_x = max((int)((pltarea_max_x-pltarea_min_x)*(double)w),(int)(w - 100*(double)(dc.GetPPI().x)/(double)72 - min_x));
int max_y = max((int)((pltarea_max_y-pltarea_min_y)*(double)h),(int)(h-160*(double)(dc.GetPPI().x)/(double)72 - min_y));
labeledplotAxes myAxes(dc, wxPoint(min_x,min_y),
wxPoint(max_x,max_y),
wxRealPoint(3.0,0.0),
wxRealPoint(15.5,1.0),
true);
dc.Clear();
myAxes.setBackgroundColor(*wxWHITE_BRUSH);
myAxes.setupDCforPlot(dc);
// myAxes.addGrid(2, 0.2);
wxArrayDouble xtickpoints;
wxArrayDouble ytickpoints;
int i,j;
wxArrayString x_tick_labels;
wxArrayString y_tick_labels;
for (i=3; i <= 15; i++){
xtickpoints.Add((double)i);
x_tick_labels.Add(wxString::Format(_T("%d"), i));
}
for (i =0; i <= 10; i++){
ytickpoints.Add((double)i/10.0);
y_tick_labels.Add(wxString::Format(_T("%.2f"), i/10.0));
}
myAxes.setTickLocationX(xtickpoints);
myAxes.setTickLocationY(ytickpoints);
myAxes.setTickLabelsX(x_tick_labels);
myAxes.setTickLabelsY(y_tick_labels);
wxString x_label = wxT("log2 PM");
wxString y_label = wxT("Density");
myAxes.setAxisLabelX(x_label);
myAxes.setAxisLabelY(y_label);
myAxes.setTitle(MyRawData->GetArrayNames()[whichdensity]);
wxPoint xsq[512];
j = whichdensity;
for (i =0; i < 512; i++){
xsq[i] = myAxes.FindPoint(wxRealPoint((*DensityPlotStatistics_x)[j*512 + i], (*DensityPlotStatistics_y)[j*512 + i]));
}
dc.DrawSpline(WXSIZEOF(xsq),xsq);
dc.DestroyClippingRegion();
myAxes.Draw(dc);
}
示例7: OnDraw
// Define the repainting behaviour
void MyCanvas::OnDraw(wxDC& dc)
{
// vars to use ...
#if wxUSE_STATUSBAR
wxString s ;
#endif // wxUSE_STATUSBAR
wxPen wP ;
wxBrush wB ;
wxPoint points[6];
wxColour wC;
wxFont wF ;
dc.SetFont(*wxSWISS_FONT);
dc.SetPen(*wxGREEN_PEN);
switch (m_index)
{
default:
case 0:
// draw lines to make a cross
dc.DrawLine(0, 0, 200, 200);
dc.DrawLine(200, 0, 0, 200);
// draw point colored line and spline
wP = *wxCYAN_PEN ;
wP.SetWidth(3);
dc.SetPen(wP);
dc.DrawPoint (25,15) ;
dc.DrawLine(50, 30, 200, 30);
dc.DrawSpline(50, 200, 50, 100, 200, 10);
#if wxUSE_STATUSBAR
s = wxT("Green Cross, Cyan Line and spline");
#endif // wxUSE_STATUSBAR
break ;
case 1:
// draw standard shapes
dc.SetBrush(*wxCYAN_BRUSH);
dc.SetPen(*wxRED_PEN);
dc.DrawRectangle(10, 10, 100, 70);
wB = wxBrush (_T("DARK ORCHID"), wxTRANSPARENT);
dc.SetBrush (wB);
dc.DrawRoundedRectangle(50, 50, 100, 70, 20);
dc.SetBrush (wxBrush(_T("GOLDENROD"), wxSOLID) );
dc.DrawEllipse(100, 100, 100, 50);
points[0].x = 100; points[0].y = 200;
points[1].x = 70; points[1].y = 260;
points[2].x = 160; points[2].y = 230;
points[3].x = 40; points[3].y = 230;
points[4].x = 130; points[4].y = 260;
points[5].x = 100; points[5].y = 200;
dc.DrawPolygon(5, points);
dc.DrawLines (6, points, 160);
#if wxUSE_STATUSBAR
s = wxT("Blue rectangle, red edge, clear rounded rectangle, gold ellipse, gold and clear stars");
#endif // wxUSE_STATUSBAR
break ;
case 2:
// draw text in Arial or similar font
dc.DrawLine(50,25,50,35);
dc.DrawLine(45,30,55,30);
dc.DrawText(wxT("This is a Swiss-style string"), 50, 30);
wC = dc.GetTextForeground() ;
dc.SetTextForeground (_T("FIREBRICK"));
// no effect in msw ??
dc.SetTextBackground (_T("WHEAT"));
dc.DrawText(wxT("This is a Red string"), 50, 200);
dc.DrawRotatedText(wxT("This is a 45 deg string"), 50, 200, 45);
dc.DrawRotatedText(wxT("This is a 90 deg string"), 50, 200, 90);
wF = wxFont ( 18, wxROMAN, wxITALIC, wxBOLD, false, wxT("Times New Roman"));
dc.SetFont(wF);
dc.SetTextForeground (wC) ;
dc.DrawText(wxT("This is a Times-style string"), 50, 60);
#if wxUSE_STATUSBAR
s = wxT("Swiss, Times text; red text, rotated and colored orange");
#endif // wxUSE_STATUSBAR
break ;
case 3 :
// four arcs start and end points, center
dc.SetBrush(*wxGREEN_BRUSH);
dc.DrawArc ( 200,300, 370,230, 300,300 );
dc.SetBrush(*wxBLUE_BRUSH);
dc.DrawArc ( 270-50, 270-86, 270-86, 270-50, 270,270 );
dc.SetDeviceOrigin(-10,-10);
dc.DrawArc ( 270-50, 270-86, 270-86, 270-50, 270,270 );
dc.SetDeviceOrigin(0,0);
wP.SetColour (_T("CADET BLUE"));
dc.SetPen(wP);
dc.DrawArc ( 75,125, 110, 40, 75, 75 );
wP.SetColour (_T("SALMON"));
dc.SetPen(wP);
//.........这里部分代码省略.........
示例8: drawUserInterface
//.........这里部分代码省略.........
// draw coordinate system
if (_style & DRAW_LOCAL_COORDINATE_SYSTEM)
{
dc.SetPen(greenPen);
}
else
{
dc.SetPen(whitePen);
}
dc.DrawLine(pos.x + 2, pos.y + 3, pos.x + 2, pos.y + _buttonSize - 2);
dc.DrawLine(pos.x + 2, pos.y + _buttonSize - 2, size.x - 3, pos.y + _buttonSize - 2);
dc.DrawLine(pos.x + 2, pos.y + _buttonSize - 2, pos.x + _buttonSize - 6, pos.y + _buttonSizeHalf + 2);
pos.y += _buttonSize;
// draw joint constraints
if (_style & DRAW_JOINT_CONSTRAINTS)
{
dc.SetPen(greenPen);
}
else
{
dc.SetPen(whitePen);
}
//dc.DrawCircle(pos.x + _buttonSizeHalf, pos.y + _buttonSizeHalf, _buttonSizeHalf - 3);
//dc.DrawArc(pos.x + 4, pos.y + 5, pos.x + 4, pos.y + _buttonSize - 5, pos.x + _buttonSizeHalf + 2, pos.y + _buttonSizeHalf);
//dc.DrawCircle(pos.x + 6, pos.y + _buttonSizeHalf, 3);
dc.DrawEllipse(pos.x + 4, pos.y + 3, _buttonSizeHalf - 5, _buttonSizeHalf + 4);
dc.DrawLine(pos.x + 8, pos.y + 3, pos.x + _buttonSizeHalf + 5, pos.y + _buttonSizeHalf);
dc.DrawLine(pos.x + 8, pos.y + _buttonSizeHalf + 7, pos.x + _buttonSizeHalf + 5, pos.y + _buttonSizeHalf);
pos.y += _buttonSize;
// draw rotation axis
if (_style & DRAW_ROTATION_AXIS)
{
dc.SetPen(greenPen);
}
else
{
dc.SetPen(whitePen);
}
dc.DrawArc(pos.x + _buttonSizeHalf + 2, pos.y + _buttonSize - 2, pos.x + _buttonSizeHalf, pos.y + _buttonSizeHalf + 1, pos.x + 2, pos.y + _buttonSize - 2);
//dc.DrawEllipse(pos.x + 6, pos.y + 5, _buttonSize - 12, _buttonSize - 10);
//dc.DrawCircle(pos.x + _buttonSizeHalf + 2, pos.y + _buttonSizeHalf - 2, 3);
dc.DrawLine(pos.x + 2, pos.y + _buttonSize - 2, pos.x + _buttonSize - 2, pos.y + 2);
dc.DrawLine(pos.x + 2, pos.y + _buttonSize - 2, pos.x + _buttonSize - 2, pos.y + _buttonSize - 2);
pos.y += _buttonSize;
// draw label
if (_style & DRAW_LABEL)
{
dc.SetPen(greenPen);
}
else
{
dc.SetPen(whitePen);
}
dc.DrawRoundedRectangle(pos.x + 4, pos.y + 3, _buttonSize - 5, _buttonSizeHalf, 3.0);
dc.DrawSpline(pos.x + 4, pos.y + _buttonSizeHalf - 3, pos.x + 1, pos.y + _buttonSizeHalf + 4, pos.x + _buttonSizeHalf + 4, pos.y + _buttonSizeHalf + 6);
pos.y += _buttonSize;
// draw locate skeleton button
dc.SetPen(whitePen);
dc.DrawLine(pos.x + _buttonSizeHalf, pos.y + 2, pos.x + _buttonSizeHalf, pos.y + _buttonSize - 1);
dc.DrawLine(pos.x + 2, pos.y + _buttonSizeHalf, size.x - 1, pos.y + _buttonSizeHalf);
dc.DrawCircle(pos.x + _buttonSizeHalf, pos.y + _buttonSizeHalf, _buttonSizeHalf - 4);
brush.SetColour(wxColour(255, 255, 255));
dc.SetBrush(brush);
dc.DrawCircle(pos.x + _buttonSizeHalf, pos.y + _buttonSizeHalf, _buttonSizeHalf - 8);
pos.y += _buttonSize;
// draw settings button
dc.DrawCircle(pos.x + _buttonSizeHalf, pos.y + _buttonSizeHalf, _buttonSizeHalf - 3);
dc.SetPen(blackPen);
brush.SetColour(wxColour(0, 0, 0));
dc.SetBrush(brush);
dc.DrawCircle(pos.x + _buttonSizeHalf + 6, pos.y + _buttonSizeHalf, 2);
dc.DrawCircle(pos.x + _buttonSizeHalf - 6, pos.y + _buttonSizeHalf, 2);
dc.DrawCircle(pos.x + _buttonSizeHalf, pos.y + _buttonSizeHalf + 6, 2);
dc.DrawCircle(pos.x + _buttonSizeHalf, pos.y + _buttonSizeHalf - 6, 2);
dc.SetPen(whitePen);
dc.DrawCircle(pos.x + _buttonSizeHalf, pos.y + _buttonSizeHalf, _buttonSizeHalf - 7);
}