Defines the rendering style of control points for PlanarFigure objects. More...
#include <mitkPlanarFigureControlPointStyleProperty.h>
Public Types | |
enum | Shape { Square, Circle } |
typedef PlanarFigureControlPointStyleProperty | Self |
typedef EnumerationProperty | Superclass |
typedef itk::SmartPointer< Self > | Pointer |
typedef itk::SmartPointer < const Self > | ConstPointer |
Public Member Functions | |
virtual const char * | GetClassName () const |
virtual Shape | GetShape () |
virtual void | SetShape (Shape) |
Static Public Member Functions | |
static Pointer | New () |
static Pointer | New (const IdType &_arg) |
static Pointer | New (const std::string &_arg) |
Protected Member Functions | |
PlanarFigureControlPointStyleProperty () | |
PlanarFigureControlPointStyleProperty (const IdType &value) | |
PlanarFigureControlPointStyleProperty (const std::string &value) | |
virtual bool | AddEnum (const std::string &name, const IdType &id) |
virtual void | AddEnumTypes () |
Defines the rendering style of control points for PlanarFigure objects.
Used by PlanarFigureMapper2D to determine which of several control point shapes to use. Currently this is basically the choice between squares and circles. If more options are implemented, this class should be enhanced.
After construction, the default shape is a square.
Definition at line 40 of file mitkPlanarFigureControlPointStyleProperty.h.
typedef itk::SmartPointer<const Self> mitk::PlanarFigureControlPointStyleProperty::ConstPointer |
Reimplemented from mitk::EnumerationProperty.
Definition at line 44 of file mitkPlanarFigureControlPointStyleProperty.h.
typedef itk::SmartPointer<Self> mitk::PlanarFigureControlPointStyleProperty::Pointer |
Reimplemented from mitk::EnumerationProperty.
Definition at line 44 of file mitkPlanarFigureControlPointStyleProperty.h.
Reimplemented from mitk::EnumerationProperty.
Definition at line 44 of file mitkPlanarFigureControlPointStyleProperty.h.
Reimplemented from mitk::EnumerationProperty.
Definition at line 44 of file mitkPlanarFigureControlPointStyleProperty.h.
Definition at line 52 of file mitkPlanarFigureControlPointStyleProperty.h.
mitk::PlanarFigureControlPointStyleProperty::PlanarFigureControlPointStyleProperty | ( | ) | [protected] |
Definition at line 3 of file mitkPlanarFigureControlPointStyleProperty.cpp.
References AddEnumTypes(), mitk::EnumerationProperty::SetValue(), and Square.
{ this->AddEnumTypes(); this->SetValue( static_cast<IdType> ( Square ) ); }
mitk::PlanarFigureControlPointStyleProperty::PlanarFigureControlPointStyleProperty | ( | const IdType & | value ) | [protected] |
Definition at line 9 of file mitkPlanarFigureControlPointStyleProperty.cpp.
{ this->AddEnumTypes(); if ( this->IsValidEnumerationValue( value ) ) { this->SetValue( value ) ; } else { this->SetValue( static_cast<IdType> ( Square ) ); } }
mitk::PlanarFigureControlPointStyleProperty::PlanarFigureControlPointStyleProperty | ( | const std::string & | value ) | [protected] |
Constructor. Sets the decoration type to the given value. If it is not valid, the representation is set to none
Definition at line 22 of file mitkPlanarFigureControlPointStyleProperty.cpp.
{ this->AddEnumTypes(); if ( this->IsValidEnumerationValue( value ) ) { this->SetValue( value ); } else { this->SetValue( static_cast<IdType>( Square ) ); } }
bool mitk::PlanarFigureControlPointStyleProperty::AddEnum | ( | const std::string & | name, |
const IdType & | id | ||
) | [protected, virtual] |
this function is overridden as protected, so that the user may not add additional invalid types.
Reimplemented from mitk::EnumerationProperty.
Definition at line 44 of file mitkPlanarFigureControlPointStyleProperty.cpp.
{ return Superclass::AddEnum( name, id ); }
void mitk::PlanarFigureControlPointStyleProperty::AddEnumTypes | ( | ) | [protected, virtual] |
Adds the standard enumeration types with corresponding strings.
Definition at line 37 of file mitkPlanarFigureControlPointStyleProperty.cpp.
Referenced by PlanarFigureControlPointStyleProperty().
virtual const char* mitk::PlanarFigureControlPointStyleProperty::GetClassName | ( | ) | const [virtual] |
Reimplemented from mitk::EnumerationProperty.
mitk::PlanarFigureControlPointStyleProperty::Shape mitk::PlanarFigureControlPointStyleProperty::GetShape | ( | ) | [virtual] |
Definition at line 49 of file mitkPlanarFigureControlPointStyleProperty.cpp.
Referenced by mitk::PlanarFigureMapper2D::InitializePlanarFigurePropertiesFromDataNode().
{ return static_cast<mitk::PlanarFigureControlPointStyleProperty::Shape>( this->GetValueAsId() ); }
static Pointer mitk::PlanarFigureControlPointStyleProperty::New | ( | ) | [static] |
Reimplemented from mitk::EnumerationProperty.
static Pointer mitk::PlanarFigureControlPointStyleProperty::New | ( | const std::string & | _arg ) | [inline, static] |
Definition at line 50 of file mitkPlanarFigureControlPointStyleProperty.h.
{
static Pointer mitk::PlanarFigureControlPointStyleProperty::New | ( | const IdType & | _arg ) | [inline, static] |
Definition at line 48 of file mitkPlanarFigureControlPointStyleProperty.h.
void mitk::PlanarFigureControlPointStyleProperty::SetShape | ( | Shape | shape ) | [virtual] |
Definition at line 55 of file mitkPlanarFigureControlPointStyleProperty.cpp.
{ this->SetValue( static_cast<IdType>( shape ) ); }