VTK
vtkQtChartSeriesSelectionModel.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkQtChartSeriesSelectionModel.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 _vtkQtChartSeriesSelectionModel_h
25 #define _vtkQtChartSeriesSelectionModel_h
26 
27 #include "vtkQtChartExport.h"
28 #include <QObject>
29 
32 
33 
38 class VTKQTCHART_EXPORT vtkQtChartSeriesSelectionModel : public QObject
39 {
40  Q_OBJECT
41 
42 public:
46  vtkQtChartSeriesSelectionModel(QObject *parent=0);
48 
53  vtkQtChartSeriesModel *getModel() const {return this->Model;}
54 
58  void setModel(vtkQtChartSeriesModel *model);
59 
66  bool isInInteractiveChange() const {return this->InInteractMode;}
67 
91  void beginInteractiveChange();
92 
96  void endInteractiveChange();
97 
102  bool isSelectionEmpty() const;
103 
108  const vtkQtChartSeriesSelection &getSelection() const;
109 
111  void selectAllSeries();
112 
114  void selectAllPoints();
115 
117  void selectNone();
118 
120  void selectInverse();
121 
125  void setSelection(const vtkQtChartSeriesSelection &selection);
126 
130  void addSelection(const vtkQtChartSeriesSelection &selection);
131 
135  void subtractSelection(const vtkQtChartSeriesSelection &selection);
136 
141  void xorSelection(const vtkQtChartSeriesSelection &selection);
142 
143 signals:
147  void selectionChanged(const vtkQtChartSeriesSelection &list);
148 
156  void interactionFinished();
157 
158 public slots:
160 
161  void beginModelReset();
167 
169  void endModelReset();
170 
180  void beginInsertSeries(int first, int last);
181 
186  void endInsertSeries(int first, int last);
187 
198  void beginRemoveSeries(int first, int last);
199 
204  void endRemoveSeries(int first, int last);
206 
207 private:
209  void limitSelection();
210 
211 private:
213  vtkQtChartSeriesSelection *Selection;
214  vtkQtChartSeriesModel *Model;
215  bool PendingSignal;
216  bool InInteractMode;
217 };
218 
219 #endif
The vtkQtChartSeriesSelection class is used for series and point selection.
The vtkQtChartSeriesModel class is the base class for all chart series models.
The vtkQtChartSeriesSelectionModel class ties a series selection to a series model.
bool isInInteractiveChange() const
Gets whether or not the selection model is in an interactive change.
vtkQtChartSeriesModel * getModel() const
Gets the series model associated with the selection model.