+void wxBitmapButton::DrawFace( WXHDC dc, int left, int top, int right, int bottom, bool sel )
+{
+ HPEN oldp;
+ HPEN penBorder;
+ HPEN penLight;
+ HPEN penShadow;
+ HBRUSH brushFace;
+
+ // create needed pens and brush
+ penBorder = CreatePen(PS_SOLID, 0, GetSysColor(COLOR_WINDOWFRAME));
+ penShadow = CreatePen(PS_SOLID, 0, GetSysColor(COLOR_BTNSHADOW));
+ penLight = CreatePen(PS_SOLID, 0, GetSysColor(COLOR_BTNHIGHLIGHT));
+ brushFace = CreateSolidBrush(COLOR_BTNFACE);
+
+ // draw the rectangle
+ RECT rect;
+ rect.left = left;
+ rect.right = right;
+ rect.top = top;
+ rect.bottom = bottom;
+ FillRect((HDC) dc, &rect, brushFace);
+
+ // draw the border
+ oldp = (HPEN) SelectObject( (HDC) dc, penBorder);
+ MoveToEx((HDC) dc,left+1,top,NULL);LineTo((HDC) dc,right-1,top);
+ MoveToEx((HDC) dc,left,top+1,NULL);LineTo((HDC) dc,left,bottom-1);
+ MoveToEx((HDC) dc,left+1,bottom-1,NULL);LineTo((HDC) dc,right-1,bottom-1);
+ MoveToEx((HDC) dc,right-1,top+1,NULL);LineTo((HDC) dc,right-1,bottom-1);
+
+ SelectObject( (HDC) dc, penShadow);