00001 #ifndef WXMGRVIEWDIALOGLEGENDCANVAS_H_INCLUDED
00002 #define WXMGRVIEWDIALOGLEGENDCANVAS_H_INCLUDED
00003
00004 #include <wx/wx.h>
00005 #include <wx/dc.h>
00006
00007
00008 #include "../inc/Legend.h"
00009
00017 class wxLegendCanvas: public wxScrolledWindow
00018 {
00019 public:
00020 wxLegendCanvas(wxDialog* parent, FemViewer::Legend& legend, const wxSize& size = wxDefaultSize);
00021 ~wxLegendCanvas();
00022
00023 FemViewer::Legend& legend;
00024
00025 protected:
00026
00027 private:
00028
00029 wxRadioBox *m_radioColGrad;
00030
00031 void OnPaint(wxPaintEvent &event);
00032 void OnPaint2(wxPaintEvent &event);
00033 void OnPaint3(wxPaintEvent &event);
00034
00035 void GradientFillLinear(wxDC &dc, const wxRect& rect, FemViewer::colormap_value& initial, FemViewer::colormap_value& dest, wxDirection nDirection);
00036
00037 DECLARE_EVENT_TABLE()
00038
00039
00040
00041 };
00042
00043
00044 #endif // WXMGRVIEWDIALOGLEGENDCANVAS_H_INCLUDED