Wt examples  4.3.0
ChartConfig.h
Go to the documentation of this file.
1 // This may look like C code, but it's really -*- C++ -*-
2 /*
3  * Copyright (C) 2008 Emweb bv, Herent, Belgium.
4  *
5  * See the LICENSE file for terms of use.
6  */
7 #ifndef CHART_CONFIG_H_
8 #define CHART_CONFIG_H_
9 
10 #include <Wt/WContainerWidget.h>
11 #include <Wt/Chart/WDataSeries.h>
12 
13 namespace Wt {
14  class WCheckBox;
15  class WComboBox;
16  class WFormWidget;
17  class WLineEdit;
18  class WStandardItemModel;
19  class WTable;
20  class WValidator;
21 
22  namespace Chart {
23  class WAxis;
24  class WCartesianChart;
25  }
26 }
27 
32 
41 {
42 public:
46 
48 
49 private:
52 
54  struct SeriesControl {
62  };
63 
65  std::vector<SeriesControl> seriesControls_;
66 
68  struct AxisControl {
80  };
81 
83  std::vector<AxisControl> axisControls_;
84 
93 
94  std::shared_ptr<Wt::WStandardItemModel> yAxesModel_, xScales_, yScales_;
96  std::shared_ptr<Wt::WValidator> anyNumberValidator_, angleValidator_;
97 
99  void update();
100  void addYAxis();
101  void addAxis(Wt::Chart::Axis axis, int yAxis);
102  void removeYAxis(const Wt::Chart::WAxis *axis);
103  void clearYAxes();
104 
105  static bool validate(Wt::WFormWidget *w);
106 };
107 
110 #endif // CHARTS_EXAMPLE_H_
ChartConfig::AxisControl::visibleEdit
Wt::WCheckBox * visibleEdit
Definition: ChartConfig.h:69
ChartConfig::SeriesControl::axisEdit
Wt::WComboBox * axisEdit
Definition: ChartConfig.h:58
ChartConfig::AxisControl::autoEdit
Wt::WCheckBox * autoEdit
Definition: ChartConfig.h:71
ChartConfig::AxisControl::titleEdit
Wt::WLineEdit * titleEdit
Definition: ChartConfig.h:76
Wt
ChartConfig::yAxesModel_
std::shared_ptr< Wt::WStandardItemModel > yAxesModel_
Definition: ChartConfig.h:94
ChartConfig::AxisControl::minimumEdit
Wt::WLineEdit * minimumEdit
Definition: ChartConfig.h:72
ChartConfig::angleValidator_
std::shared_ptr< Wt::WValidator > angleValidator_
Definition: ChartConfig.h:96
ChartConfig::xScales_
std::shared_ptr< Wt::WStandardItemModel > xScales_
Definition: ChartConfig.h:94
ChartConfig::connectSignals
void connectSignals(Wt::WFormWidget *w)
Definition: ChartConfig.C:651
Wt::WContainerWidget
ChartConfig::titleEdit_
Wt::WLineEdit * titleEdit_
Definition: ChartConfig.h:85
ChartConfig::SeriesControl::markerEdit
Wt::WComboBox * markerEdit
Definition: ChartConfig.h:57
ChartConfig::SeriesControl::typeEdit
Wt::WComboBox * typeEdit
Definition: ChartConfig.h:56
ChartConfig::fill_
Wt::Chart::FillRangeType fill_
Definition: ChartConfig.h:51
ChartConfig::SeriesControl::enabledEdit
Wt::WCheckBox * enabledEdit
Definition: ChartConfig.h:55
ChartConfig::AxisControl::scaleEdit
Wt::WComboBox * scaleEdit
Definition: ChartConfig.h:70
ChartConfig::chart_
Wt::Chart::WCartesianChart * chart_
Definition: ChartConfig.h:50
Wt::WLineEdit
ChartConfig::axisConfig_
Wt::WTable * axisConfig_
Definition: ChartConfig.h:95
ChartConfig::chartWidthEdit_
Wt::WLineEdit * chartWidthEdit_
Definition: ChartConfig.h:86
Wt::WFormWidget
ChartConfig::AxisControl::titleOrientationEdit
Wt::WComboBox * titleOrientationEdit
Definition: ChartConfig.h:77
ChartConfig::seriesControls_
std::vector< SeriesControl > seriesControls_
Controls for series.
Definition: ChartConfig.h:65
ChartConfig::legendSideEdit_
Wt::WComboBox * legendSideEdit_
Definition: ChartConfig.h:90
ChartConfig::update
void update()
Definition: ChartConfig.C:383
Wt::WComboBox
ChartConfig
A class that allows configuration of a cartesian chart.
Definition: ChartConfig.h:40
ChartConfig::AxisControl::maximumEdit
Wt::WLineEdit * maximumEdit
Definition: ChartConfig.h:73
ChartConfig::removeYAxis
void removeYAxis(const Wt::Chart::WAxis *axis)
Definition: ChartConfig.C:766
ChartConfig::AxisControl
Struct that holds the controls for one axis.
Definition: ChartConfig.h:68
ChartConfig::SeriesControl::shadowEdit
Wt::WCheckBox * shadowEdit
Definition: ChartConfig.h:60
Wt::WTable
ChartConfig::chartOrientationEdit_
Wt::WComboBox * chartOrientationEdit_
Definition: ChartConfig.h:88
ChartConfig::SeriesControl
Struct that holds the controls for one series.
Definition: ChartConfig.h:54
Wt::Chart::WCartesianChart
ChartConfig::legendLocationEdit_
Wt::WComboBox * legendLocationEdit_
Definition: ChartConfig.h:89
ChartConfig::clearYAxes
void clearYAxes()
Definition: ChartConfig.C:780
ChartConfig::axisControls_
std::vector< AxisControl > axisControls_
Controls for axes.
Definition: ChartConfig.h:83
Wt::Chart::FillRangeType
FillRangeType
Wt::Chart::Axis
Axis
ChartConfig::addYAxis
void addYAxis()
Definition: ChartConfig.C:658
ChartConfig::legendAlignmentEdit_
Wt::WComboBox * legendAlignmentEdit_
Definition: ChartConfig.h:91
ChartConfig::chartHeightEdit_
Wt::WLineEdit * chartHeightEdit_
Definition: ChartConfig.h:87
Wt::WCheckBox
ChartConfig::SeriesControl::legendEdit
Wt::WCheckBox * legendEdit
Definition: ChartConfig.h:59
ChartConfig::SeriesControl::labelsEdit
Wt::WComboBox * labelsEdit
Definition: ChartConfig.h:61
ChartConfig::setValueFill
void setValueFill(Wt::Chart::FillRangeType fill)
Definition: ChartConfig.C:378
ChartConfig::AxisControl::gridLinesEdit
Wt::WCheckBox * gridLinesEdit
Definition: ChartConfig.h:74
ChartConfig::ChartConfig
ChartConfig(Wt::Chart::WCartesianChart *chart)
Constructor.
Definition: ChartConfig.C:76
ChartConfig::borderEdit_
Wt::WCheckBox * borderEdit_
Definition: ChartConfig.h:92
Wt::Chart::WAxis
ChartConfig::validate
static bool validate(Wt::WFormWidget *w)
Definition: ChartConfig.C:639
ChartConfig::AxisControl::locationEdit
Wt::WComboBox * locationEdit
Definition: ChartConfig.h:79
ChartConfig::AxisControl::tickDirectionEdit
Wt::WComboBox * tickDirectionEdit
Definition: ChartConfig.h:78
ChartConfig::addAxis
void addAxis(Wt::Chart::Axis axis, int yAxis)
Definition: ChartConfig.C:667
ChartConfig::AxisControl::labelAngleEdit
Wt::WLineEdit * labelAngleEdit
Definition: ChartConfig.h:75
ChartConfig::yScales_
std::shared_ptr< Wt::WStandardItemModel > yScales_
Definition: ChartConfig.h:94
ChartConfig::anyNumberValidator_
std::shared_ptr< Wt::WValidator > anyNumberValidator_
Definition: ChartConfig.h:96

Generated on Thu Mar 26 2020 for the C++ Web Toolkit (Wt) by doxygen 1.8.17