VTK  9.1.0
vtkChartParallelCoordinates.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkChartParallelCoordinates.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
33#ifndef vtkChartParallelCoordinates_h
34#define vtkChartParallelCoordinates_h
35
36#include "vtkChart.h"
37#include "vtkChartsCoreModule.h" // For export macro
38#include "vtkNew.h" // For vtkNew
39
40class vtkIdTypeArray;
41class vtkStdString;
42class vtkStringArray;
44
45class VTKCHARTSCORE_EXPORT vtkChartParallelCoordinates : public vtkChart
46{
47public:
49 void PrintSelf(ostream& os, vtkIndent indent) override;
50
55
61 void Update() override;
62
66 bool Paint(vtkContext2D* painter) override;
67
71 void SetColumnVisibility(const vtkStdString& name, bool visible);
72
77 void SetColumnVisibilityAll(bool visible);
78
83
88
92 virtual void SetVisibleColumns(vtkStringArray* visColumns);
93
98
103
107 vtkAxis* GetAxis(int axisIndex) override;
108
113
118 void RecalculateBounds() override;
119
125
129 bool Hit(const vtkContextMouseEvent& mouse) override;
130
134 bool MouseEnterEvent(const vtkContextMouseEvent& mouse) override;
135
139 bool MouseMoveEvent(const vtkContextMouseEvent& mouse) override;
140
144 bool MouseLeaveEvent(const vtkContextMouseEvent& mouse) override;
145
149 bool MouseButtonPressEvent(const vtkContextMouseEvent& mouse) override;
150
155
159 bool MouseWheelEvent(const vtkContextMouseEvent& mouse, int delta) override;
160
161protected:
164
166
169 class Private;
170 Private* Storage;
172
174
179
184
189
191 bool ResetAxeSelection(int axe);
195 void SwapAxes(int a1, int a2);
196
197private:
199 void operator=(const vtkChartParallelCoordinates&) = delete;
200};
201
202#endif // vtkChartParallelCoordinates_h
takes care of drawing 2D axes
Definition: vtkAxis.h:78
Factory class for drawing 2D charts.
bool MouseMoveEvent(const vtkContextMouseEvent &mouse) override
Mouse move event.
vtkNew< vtkStringArray > VisibleColumns
Strongly owned internal data for the column visibility.
bool ResetAxeSelection(int axe)
vtkAxis * GetAxis(int axisIndex) override
Get the axis specified by axisIndex.
virtual void SetVisibleColumns(vtkStringArray *visColumns)
Set the list of visible columns, and the order in which they will be displayed.
vtkTimeStamp BuildTime
The point cache is marked dirty until it has been initialized.
vtkIdType GetNumberOfAxes() override
Get the number of axes in the current chart.
bool GetColumnVisibility(const vtkStdString &name)
Get the visibility of the specified column.
bool Hit(const vtkContextMouseEvent &mouse) override
Return true if the supplied x, y coordinate is inside the item.
vtkPlot * GetPlot(vtkIdType index) override
Get the plot at the specified index, returns null if the index is invalid.
void RecalculateBounds() override
Request that the chart recalculates the range of its axes.
virtual vtkStringArray * GetVisibleColumns()
Get a list of the columns, and the order in which they are displayed.
void SetColumnVisibility(const vtkStdString &name, bool visible)
Set the visibility of the specified column.
bool MouseWheelEvent(const vtkContextMouseEvent &mouse, int delta) override
Mouse wheel event, positive delta indicates forward movement of the wheel.
void SetColumnVisibilityAll(bool visible)
Set the visibility of all columns (true will make them all visible, false will remove all visible col...
bool MouseEnterEvent(const vtkContextMouseEvent &mouse) override
Mouse enter event.
static vtkChartParallelCoordinates * New()
Creates a parallel coordinates chart.
vtkIdTypeArray * Selection
Selected indices for the table the plot is rendering.
vtkIdType GetNumberOfPlots() override
Get the number of plots the chart contains.
bool Paint(vtkContext2D *painter) override
Paint event for the chart, called whenever the chart needs to be drawn.
bool MouseLeaveEvent(const vtkContextMouseEvent &mouse) override
Mouse leave event.
bool MouseButtonReleaseEvent(const vtkContextMouseEvent &mouse) override
Mouse button release event.
bool MouseButtonPressEvent(const vtkContextMouseEvent &mouse) override
Mouse button down event.
virtual void SetPlot(vtkPlotParallelCoordinates *plot)
Set plot to use for the chart.
void Update() override
Perform any updates to the item that may be necessary before rendering.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
~vtkChartParallelCoordinates() override
void SwapAxes(int a1, int a2)
Factory class for drawing 2D charts.
Definition: vtkChart.h:54
Class for drawing 2D primitives to a graphical context.
Definition: vtkContext2D.h:63
data structure to represent mouse events.
dynamic, self-adjusting array of vtkIdType
a simple class to control print indentation
Definition: vtkIndent.h:43
Class for drawing a parallel coordinate plot given columns from a vtkTable.
Abstract class for 2D plots.
Definition: vtkPlot.h:57
Wrapper around std::string to keep symbols short.
Definition: vtkStdString.h:45
a vtkAbstractArray subclass for strings
record modification and/or execution time
Definition: vtkTimeStamp.h:42
@ name
Definition: vtkX3D.h:225
@ index
Definition: vtkX3D.h:252
int vtkIdType
Definition: vtkType.h:332