Restructure src folder. Add asset folder. Automatically pack files from asset folder...
[fltk_mvc_template.git] / _template / src / ViewFluid.h
1 // generated by Fast Light User Interface Designer (fluid) version 1.0304
2
3 #ifndef ViewFluid_h
4 #define ViewFluid_h
5 #include <FL/Fl.H>
6 #include <FL/fl_draw.H>
7 #include <FL/Fl_Table_Row.H>
8 #include <string>
9 #include <vector>
10
11 class SimpleTable : public Fl_Table_Row {
12 public:
13   void draw_cell(TableContext context, int R=0, int C=0, int X=0, int Y=0, int W=0, int H=0);
14   SimpleTable(int x, int y, int w, int h, const char *l = 0) ;
15   void SetTableData(std::string data, unsigned int x = 0, unsigned int y = 0, Fl_Color color = FL_WHITE);
16   void SetCellColor(Fl_Color color, unsigned int x = 0, unsigned int y = 0);
17   std::vector<std::vector<std::string>> GetTableData();
18   void Resize(unsigned int x = 0, unsigned int y = 0);
19 using TableData = std::vector<std::vector<std::string>>;
20 using TableCellColors = std::vector<std::vector<Fl_Color>>;
21 private:
22   void DrawData(const char *s, Fl_Color cell_color, int X, int Y, int W, int H);
23   void DrawHeader(const char *s, int X, int Y, int W, int H);
24   TableData m_TableData; 
25   TableCellColors m_CellColors; 
26 };
27 #include <FL/Fl_Double_Window.H>
28 #include <FL/Fl_Button.H>
29
30 class ViewFluid {
31 protected:
32   ViewFluid();
33   Fl_Double_Window *win_exmpl;
34   Fl_Button *btn_exception;
35   SimpleTable *tbl_example;
36 };
37 #endif