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

#include <vtkLabelSizeCalculator.h>

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

List of all members.

Public Types

typedef vtkPassInputTypeAlgorithm Superclass

Public Member Functions

virtual void PrintSelf (ostream &os, vtkIndent indent)
virtual int IsA (const char *type)
vtkLabelSizeCalculatorNewInstance () const
virtual void SetFontProperty (vtkTextProperty *fontProp, int type=0)
virtual vtkTextPropertyGetFontProperty (int type=0)
virtual void SetLabelSizeArrayName (const char *)
virtual char * GetLabelSizeArrayName ()

Static Public Member Functions

static vtkLabelSizeCalculatorNew ()
static int IsTypeOf (const char *type)
static vtkLabelSizeCalculatorSafeDownCast (vtkObjectBase *o)

Protected Member Functions

virtual vtkObjectBaseNewInstanceInternal () const
 vtkLabelSizeCalculator ()
virtual ~vtkLabelSizeCalculator ()
virtual int FillInputPortInformation (int port, vtkInformation *info)
virtual int RequestData (vtkInformation *request, vtkInformationVector **inInfo, vtkInformationVector *outInfo)
virtual vtkIntArrayLabelSizesForArray (vtkAbstractArray *labels, vtkIntArray *types)
virtual void SetFontUtil (vtkFreeTypeUtilities *fontProp)
virtual vtkFreeTypeUtilitiesGetFontUtil ()

Protected Attributes

vtkFreeTypeUtilitiesFontUtil
char * LabelSizeArrayName
Internals * Implementation

Detailed Description

This filter takes an input dataset, an array to process (which must be a string array), and a text property. It creates a new output array (named "LabelSize" by default) with 4 components per tuple that contain the width, height, horizontal offset, and descender height (in that order) of each string in the array.

Use the inherited SelectInputArrayToProcess to indicate a string array. In no input array is specified, the first of the following that is a string array is used: point scalars, cell scalars, field scalars.

The second input array to process is an array specifying the type of each label. Different label types may have different font properties. This array must be a vtkIntArray. Any type that does not map to a font property that was set will be set to the type 0's type property.

Tests:
vtkLabelSizeCalculator (Tests)

Definition at line 50 of file vtkLabelSizeCalculator.h.


Member Typedef Documentation

Reimplemented from vtkPassInputTypeAlgorithm.

Definition at line 55 of file vtkLabelSizeCalculator.h.


Constructor & Destructor Documentation

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

Member Function Documentation

Create an object with Debug turned off, modified time initialized to zero, and reference counting on.

Reimplemented from vtkPassInputTypeAlgorithm.

virtual void vtkLabelSizeCalculator::PrintSelf ( ostream &  os,
vtkIndent  indent 
) [virtual]

Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Reimplemented from vtkPassInputTypeAlgorithm.

static int vtkLabelSizeCalculator::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 vtkPassInputTypeAlgorithm.

virtual int vtkLabelSizeCalculator::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 vtkPassInputTypeAlgorithm.

Reimplemented from vtkPassInputTypeAlgorithm.

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

Reimplemented from vtkPassInputTypeAlgorithm.

Reimplemented from vtkPassInputTypeAlgorithm.

virtual void vtkLabelSizeCalculator::SetFontProperty ( vtkTextProperty fontProp,
int  type = 0 
) [virtual]

Get/Set the font used compute label sizes. This defaults to "Arial" at 12 points. If type is provided, it refers to the type of the text label provided in the optional label type array. The default type is type 0.

Get/Set the font used compute label sizes. This defaults to "Arial" at 12 points. If type is provided, it refers to the type of the text label provided in the optional label type array. The default type is type 0.

virtual void vtkLabelSizeCalculator::SetLabelSizeArrayName ( const char *  ) [virtual]

The name of the output array containing text label sizes This defaults to "LabelSize"

virtual char* vtkLabelSizeCalculator::GetLabelSizeArrayName ( ) [virtual]

The name of the output array containing text label sizes This defaults to "LabelSize"

virtual int vtkLabelSizeCalculator::FillInputPortInformation ( int  port,
vtkInformation info 
) [protected, virtual]

Fill the input port information objects for this algorithm. This is invoked by the first call to GetInputPortInformation for each port so subclasses can specify what they can handle.

Reimplemented from vtkPassInputTypeAlgorithm.

This is called within ProcessRequest when a request asks the algorithm to do its work. This is the method you should override to do whatever the algorithm is designed to do. This happens during the fourth pass in the pipeline execution process.

Reimplemented from vtkPassInputTypeAlgorithm.

virtual vtkIntArray* vtkLabelSizeCalculator::LabelSizesForArray ( vtkAbstractArray labels,
vtkIntArray types 
) [protected, virtual]
virtual void vtkLabelSizeCalculator::SetFontUtil ( vtkFreeTypeUtilities fontProp) [protected, virtual]
virtual vtkFreeTypeUtilities* vtkLabelSizeCalculator::GetFontUtil ( ) [protected, virtual]

Member Data Documentation

Definition at line 86 of file vtkLabelSizeCalculator.h.

Definition at line 89 of file vtkLabelSizeCalculator.h.

Definition at line 92 of file vtkLabelSizeCalculator.h.


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