The vtkQtChartStyleManager class allows several chart layers to share the same style generator. More...
#include <vtkQtChartStyleManager.h>
Public Member Functions | |
vtkQtChartStyleManager (QObject *parent=0) | |
Creates a chart style manager. | |
virtual | ~vtkQtChartStyleManager () |
vtkQtChartStyleGenerator * | getGenerator () |
Gets the options generator. | |
void | setGenerator (vtkQtChartStyleGenerator *generator) |
Sets the options generator. | |
int | reserveStyle () |
Reserves a style index for the style generator. | |
void | releaseStyle (int index) |
Releases a series style index. |
The vtkQtChartStyleManager class allows several chart layers to share the same style generator.
Sharing a style generator keeps the style from repeating. This is useful when several chart layers are displayed in the same chart. For example, a line chart and a bar chart can share a style generator to make sure that none of the series are the same color.
Definition at line 43 of file vtkQtChartStyleManager.h.
vtkQtChartStyleManager::vtkQtChartStyleManager | ( | QObject * | parent = 0 ) |
Creates a chart style manager.
parent | The parent object. |
virtual vtkQtChartStyleManager::~vtkQtChartStyleManager | ( | ) | [inline, virtual] |
Definition at line 50 of file vtkQtChartStyleManager.h.
{}
vtkQtChartStyleGenerator* vtkQtChartStyleManager::getGenerator | ( | ) |
Gets the options generator.
void vtkQtChartStyleManager::releaseStyle | ( | int | index ) |
Releases a series style index.
When an index is released, the empty spot is saved so it can be used for the next reservation.
index | The style index to release. |
int vtkQtChartStyleManager::reserveStyle | ( | ) |
Reserves a style index for the style generator.
The index returned is the lowest index available. If there are empty spots from removals, the index will come from the first empty spot.
void vtkQtChartStyleManager::setGenerator | ( | vtkQtChartStyleGenerator * | generator ) |
Sets the options generator.
generator | The new options generator. |
Referenced by QmitkVtkLineProfileWidget::QmitkVtkLineProfileWidget().