VTK
vtkQtStatisticalBoxChart.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkQtStatisticalBoxChart.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
15 /*-------------------------------------------------------------------------
16  Copyright 2008 Sandia Corporation.
17  Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
18  the U.S. Government retains certain rights in this software.
19 -------------------------------------------------------------------------*/
20 
23 
24 #ifndef _vtkQtStatisticalBoxChart_h
25 #define _vtkQtStatisticalBoxChart_h
26 
27 #include "vtkQtChartExport.h"
28 #include "vtkQtChartSeriesLayer.h"
29 
30 class vtkQtStatisticalBoxChartInternal;
32 
36 class VTKQTCHART_EXPORT vtkQtStatisticalBoxChart : public vtkQtChartSeriesLayer
37 {
38  Q_OBJECT
39 
40 public:
42  virtual ~vtkQtStatisticalBoxChart();
43 
45 
46  virtual void setChartArea(vtkQtChartArea *area);
47 
48  virtual void setModel(vtkQtChartSeriesModel *model);
50 
52 
53  vtkQtStatisticalBoxChartOptions *getOptions() const {return this->Options;}
58 
66  void setOptions(const vtkQtStatisticalBoxChartOptions &options);
67 
68  virtual QPixmap getSeriesIcon(int series) const;
70 
72 
73  virtual void getLayerDomain(vtkQtChartLayerDomain &domain) const;
74 
75  virtual void layoutChart(const QRectF &area);
76 
77  virtual bool getHelpText(const QPointF &point, QString &text);
78 
84  virtual void finishInteractiveResize();
86 
88 
89  virtual void getSeriesAt(const QPointF &point,
90  vtkQtChartSeriesSelection &selection) const;
91 
92  virtual void getPointsAt(const QPointF &point,
93  vtkQtChartSeriesSelection &selection) const;
94 
95  virtual void getSeriesIn(const QRectF &area,
96  vtkQtChartSeriesSelection &selection) const;
97 
98  virtual void getPointsIn(const QRectF &area,
99  vtkQtChartSeriesSelection &selection) const;
101 
103 
104  virtual QRectF boundingRect() const;
105 
106  virtual void paint(QPainter *painter, const QStyleOptionGraphicsItem *option,
107  QWidget *widget=0);
109 
110 public slots:
116  void reset();
117 
118 protected slots:
127  int type, const QVariant& newvalue, const QVariant& oldvalue);
128 
129 protected:
137  virtual void setupOptions(vtkQtChartSeriesOptions *options);
138 
139 private slots:
144  void prepareSeriesInsert(int first, int last);
145 
150  void insertSeries(int first, int last);
151 
156  void startSeriesRemoval(int first, int last);
157 
162  void finishSeriesRemoval(int first, int last);
163 
165  void handleAxesCornerChange();
166 
168  void handleOutlineChange();
169 
170 
175  void updateHighlights();
176 
177 private:
184  void handleSeriesVisibilityChange(vtkQtChartSeriesOptions* options, bool visible);
185 
187  void handleSeriesPointMarkerChanged(vtkQtChartSeriesOptions*);
188 
195  bool addSeriesDomain(int series, int &seriesGroup);
196 
200  void calculateDomain(int seriesGroup);
201 
205  void createShapeTable(int seriesGroup);
206 
210  void buildShapeTree(int seriesGroup);
211 
212 private:
213  vtkQtStatisticalBoxChartInternal *Internal;
215  bool InModelChange;
216  bool BuildNeeded;
217 
218 private:
221 };
222 
223 #endif
virtual void getSeriesAt(const QPointF &point, vtkQtChartSeriesSelection &selection) const
Gets the list of series at a given position.
The vtkQtChartSeriesSelection class is used for series and point selection.
virtual void getSeriesIn(const QRectF &area, vtkQtChartSeriesSelection &selection) const
Gets the list of series in a given area.
The vtkQtChartLayerDomain class is used to merge chart layer domains.
The vtkQtChartSeriesModel class is the base class for all chart series models.
virtual void handleOptionsChanged(vtkQtChartSeriesOptions *, int type, const QVariant &newvalue, const QVariant &oldvalue)
Called when any of the series options are changed.
virtual void setChartArea(vtkQtChartArea *area)
Sets the chart area for the chart layer.
virtual void getPointsIn(const QRectF &area, vtkQtChartSeriesSelection &selection) const
Gets the list of points in a given area.
The vtkQtStatisticalBoxChart class is used to display a statistical box chart.
virtual void setModel(vtkQtChartSeriesModel *model)
Sets the chart series model.
virtual void layoutChart(const QRectF &area)=0
Used to layout the chart layer.
virtual bool getHelpText(const QPointF &point, QString &text)
Gets the help text for the given location.
The vtkQtChartSeriesLayer class is the base class for chart layers that use the chart series model...
The vtkQtChartSeriesOptions class stores the common series drawing options.
vtkQtChartSeriesOptionsModel * Options
Stores the series options.
virtual QPixmap getSeriesIcon(int series) const
Gets the icon for a given series.
virtual void finishInteractiveResize()
Notifies the chart layer that a resize interaction has finished.
The vtkQtChartArea class manages the chart axes and layers.
virtual void getPointsAt(const QPointF &point, vtkQtChartSeriesSelection &selection) const
Gets the list of points at a given position.
virtual void getLayerDomain(vtkQtChartLayerDomain &domain) const
Gets the chart layer's domain.
virtual void setupOptions(vtkQtChartSeriesOptions *options)
Sets up the default values for the series options object.
The vtkQtStatisticalBoxChartOptions class stores the drawing options for a box chart.