#include "diawxgtk.h" PUBLIC FORMBUTTON::FORMBUTTON(wxFORMBASE *_parent, const char *_id) : MFORM (_parent,_id) { Fill(); brush = NULL; pen = NULL; docolor = false; } PUBLIC FORMBUTTON::FORMBUTTON (wxFORMBASE *_parent, const char *_id, int _back) : MFORM (_parent,_id) { Fill(); if (_back){ brush = brush_white; pen = pen_white; }else{ brush = brush_back; pen = pen_back; } docolor = true; } PUBLIC FORMBUTTON::~FORMBUTTON () { } PUBLIC wxButton *FORMBUTTON::New_button(const char *_id, bool dodump, const char *str) { wxButton *ret = MFORM::New_button (_id,dodump, str); Fill(); return ret; } PUBLIC void FORMBUTTON::OnPaint () { if (docolor){ int h,w; GetSize(&w,&h); wxPaintDC dc(this); dc.SetBrush (*brush); dc.SetPen (*pen); dc.DrawRectangle (0,0,w,h); } }