VTK
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes
vtkCategoryLegend Class Reference

Legend item to display categorical data. More...

#include <vtkCategoryLegend.h>

Inheritance diagram for vtkCategoryLegend:
Inheritance graph
[legend]
Collaboration diagram for vtkCategoryLegend:
Collaboration graph
[legend]

List of all members.

Public Types

typedef vtkChartLegend Superclass
enum  { VERTICAL = 0, HORIZONTAL }

Public Member Functions

virtual int IsA (const char *type)
vtkCategoryLegendNewInstance () const
virtual bool Paint (vtkContext2D *painter)
virtual vtkRectf GetBoundingRect (vtkContext2D *painter)
virtual void SetScalarsToColors (vtkScalarsToColors *stc)
virtual vtkScalarsToColorsGetScalarsToColors ()
virtual vtkVariantArrayGetValues ()
virtual void SetValues (vtkVariantArray *)
virtual void SetTitle (const vtkStdString &title)
virtual vtkStdString GetTitle ()
virtual vtkStdString GetOutlierLabel ()
virtual void SetOutlierLabel (vtkStdString)

Static Public Member Functions

static int IsTypeOf (const char *type)
static vtkCategoryLegendSafeDownCast (vtkObjectBase *o)
static vtkCategoryLegendNew ()

Protected Member Functions

virtual vtkObjectBaseNewInstanceInternal () const
 vtkCategoryLegend ()
virtual ~vtkCategoryLegend ()

Protected Attributes

bool HasOutliers
float TitleWidthOffset
vtkScalarsToColorsScalarsToColors
vtkStdString OutlierLabel
vtkStdString Title
vtkNew< vtkTextPropertyTitleProperties
vtkVariantArrayValues

Detailed Description

Legend item to display categorical data.

vtkCategoryLegend will display a label and color patch for each value in a categorical data set. To use this class, you must first populate a vtkScalarsToColors by using the SetAnnotation() method. The other input to this class is a vtkVariantArray. This should contain the annotated values from the vtkScalarsToColors that you wish to include within the legend.

Tests:
vtkCategoryLegend (Tests)

Definition at line 43 of file vtkCategoryLegend.h.


Member Typedef Documentation

Reimplemented from vtkChartLegend.

Definition at line 46 of file vtkCategoryLegend.h.


Member Enumeration Documentation

anonymous enum

Enum of legend orientation types

Enumerator:
VERTICAL 
HORIZONTAL 

Definition at line 51 of file vtkCategoryLegend.h.


Constructor & Destructor Documentation

virtual vtkCategoryLegend::~vtkCategoryLegend ( ) [protected, virtual]

Member Function Documentation

static int vtkCategoryLegend::IsTypeOf ( const char *  name) [static]

Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkChartLegend.

virtual int vtkCategoryLegend::IsA ( const char *  name) [virtual]

Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkChartLegend.

Reimplemented from vtkChartLegend.

virtual vtkObjectBase* vtkCategoryLegend::NewInstanceInternal ( ) const [protected, virtual]

Reimplemented from vtkChartLegend.

Reimplemented from vtkChartLegend.

Creates a 2D Chart object.

Reimplemented from vtkChartLegend.

virtual bool vtkCategoryLegend::Paint ( vtkContext2D painter) [virtual]

Paint the legend into a rectangle defined by the bounds.

Reimplemented from vtkChartLegend.

virtual vtkRectf vtkCategoryLegend::GetBoundingRect ( vtkContext2D painter) [virtual]

Compute and return the lower left corner of this legend, along with its width and height.

Reimplemented from vtkChartLegend.

virtual void vtkCategoryLegend::SetScalarsToColors ( vtkScalarsToColors stc) [virtual]

Get/Set the vtkScalarsToColors used to draw this legend. Since this legend represents categorical data, this vtkScalarsToColors must have been populated using SetAnnotation().

Get/Set the vtkScalarsToColors used to draw this legend. Since this legend represents categorical data, this vtkScalarsToColors must have been populated using SetAnnotation().

Get/Set the array of values that will be represented by this legend. This array must contain distinct annotated values from the ScalarsToColors. Each value in this array will be drawn as a separate entry within this legend.

virtual void vtkCategoryLegend::SetValues ( vtkVariantArray ) [virtual]

Get/Set the array of values that will be represented by this legend. This array must contain distinct annotated values from the ScalarsToColors. Each value in this array will be drawn as a separate entry within this legend.

virtual void vtkCategoryLegend::SetTitle ( const vtkStdString title) [virtual]

Get/set the title text of the legend.

Get/set the title text of the legend.

Get/set the label to use for outlier data.

virtual void vtkCategoryLegend::SetOutlierLabel ( vtkStdString  ) [virtual]

Get/set the label to use for outlier data.


Member Data Documentation

Definition at line 97 of file vtkCategoryLegend.h.

Definition at line 98 of file vtkCategoryLegend.h.

Definition at line 99 of file vtkCategoryLegend.h.

Definition at line 100 of file vtkCategoryLegend.h.

Definition at line 101 of file vtkCategoryLegend.h.

Definition at line 102 of file vtkCategoryLegend.h.

Definition at line 103 of file vtkCategoryLegend.h.


The documentation for this class was generated from the following file: