PartGui::ViewProvider2DObject Class Reference

#include <ViewProvider2DObject.h>

Inheritance diagram for PartGui::ViewProvider2DObject:
PartGui::ViewProviderPart PartGui::ViewProviderPartExt Gui::ViewProviderGeometryObject Gui::ViewProviderDocumentObject Gui::ViewProvider App::PropertyContainer Base::Persistence Base::BaseClass SketcherGui::ViewProviderSketch SketcherGui::ViewProviderCustom

List of all members.

Public Member Functions

virtual void attach (App::DocumentObject *)
 Attaches the document object to this view provider.
SoSeparator * createGrid (void)
 creates the grid
virtual const char * getDefaultDisplayMode () const
 Get the default display mode.
virtual std::vector< std::string > getDisplayModes (void) const
 returns a list of all possible modes
virtual Base::Type getTypeId (void) const
virtual void updateData (const App::Property *)
 Gets called if some of the property hade bin changed.
 ViewProvider2DObject ()
 constructor
virtual ~ViewProvider2DObject ()
 destructor

Static Public Member Functions

static void * create (void)
static Base::Type getClassTypeId (void)
static void init (void)

Public Attributes

App::PropertyDistance GridSize
App::PropertyBool GridSnap
App::PropertyEnumeration GridStyle
App::PropertyBool ShowGrid
 Property to switch the grid on and off.
App::PropertyBool TightGrid

Protected Member Functions

virtual const App::PropertyDatagetPropertyData (void) const
virtual void onChanged (const App::Property *prop)
 get called by the container whenever a property has been changed
virtual bool setEdit (int ModNum)
 is called by the document when the provider goes in edit mode
virtual void unsetEdit (int ModNum)
 is called when you loose the edit mode

Static Protected Member Functions

static const App::PropertyDatagetPropertyDataPtr (void)

Protected Attributes

SoSeparator * GridRoot
float MaxX
float MaxY
float MinX
float MinY

Static Protected Attributes

static const char * GridStyleEnums [] = {"Dashed","Light",NULL}

Detailed Description

Definition at line 45 of file ViewProvider2DObject.h.


Constructor & Destructor Documentation

ViewProvider2DObject::ViewProvider2DObject (  ) 

constructor

Definition at line 60 of file ViewProvider2DObject.cpp.

References ADD_PROPERTY_TYPE, and App::Prop_None.

ViewProvider2DObject::~ViewProvider2DObject (  )  [virtual]

destructor

Definition at line 79 of file ViewProvider2DObject.cpp.

References GridRoot.


Member Function Documentation

void ViewProvider2DObject::attach ( App::DocumentObject pcObject  )  [virtual]

Attaches the document object to this view provider.

Reimplemented from PartGui::ViewProviderPartExt.

Reimplemented in SketcherGui::ViewProviderSketch.

Definition at line 231 of file ViewProvider2DObject.cpp.

References createGrid(), App::PropertyBool::getValue(), and ShowGrid.

void * PartGui::ViewProvider2DObject::create ( void   )  [static]

Reimplemented from PartGui::ViewProviderPart.

Reimplemented in SketcherGui::ViewProviderCustom, and SketcherGui::ViewProviderSketch.

Definition at line 58 of file ViewProvider2DObject.cpp.

SoSeparator * ViewProvider2DObject::createGrid ( void   ) 
Base::Type PartGui::ViewProvider2DObject::getClassTypeId ( void   )  [static]

Reimplemented from PartGui::ViewProviderPart.

Reimplemented in SketcherGui::ViewProviderCustom, and SketcherGui::ViewProviderSketch.

Definition at line 58 of file ViewProvider2DObject.cpp.

Referenced by updateData().

const char * ViewProvider2DObject::getDefaultDisplayMode (  )  const [virtual]

Get the default display mode.

Reimplemented from Gui::ViewProviderDocumentObject.

Definition at line 263 of file ViewProvider2DObject.cpp.

std::vector< std::string > ViewProvider2DObject::getDisplayModes ( void   )  const [virtual]

returns a list of all possible modes

Reimplemented from PartGui::ViewProviderPartExt.

Definition at line 249 of file ViewProvider2DObject.cpp.

const App::PropertyData & PartGui::ViewProvider2DObject::getPropertyData ( void   )  const [protected, virtual]

Reimplemented from PartGui::ViewProviderPart.

Reimplemented in SketcherGui::ViewProviderCustom, and SketcherGui::ViewProviderSketch.

Definition at line 58 of file ViewProvider2DObject.cpp.

const App::PropertyData * PartGui::ViewProvider2DObject::getPropertyDataPtr ( void   )  [static, protected]

Reimplemented from PartGui::ViewProviderPart.

Reimplemented in SketcherGui::ViewProviderCustom, and SketcherGui::ViewProviderSketch.

Definition at line 58 of file ViewProvider2DObject.cpp.

Base::Type PartGui::ViewProvider2DObject::getTypeId ( void   )  const [virtual]

Reimplemented from PartGui::ViewProviderPart.

Reimplemented in SketcherGui::ViewProviderCustom, and SketcherGui::ViewProviderSketch.

Definition at line 58 of file ViewProvider2DObject.cpp.

void PartGui::ViewProvider2DObject::init ( void   )  [static]

Reimplemented from PartGui::ViewProviderPart.

Reimplemented in SketcherGui::ViewProviderCustom, and SketcherGui::ViewProviderSketch.

Definition at line 58 of file ViewProvider2DObject.cpp.

Referenced by initPartGui().

void ViewProvider2DObject::onChanged ( const App::Property prop  )  [protected, virtual]

get called by the container whenever a property has been changed

Reimplemented from PartGui::ViewProviderPartExt.

Reimplemented in SketcherGui::ViewProviderCustom, and SketcherGui::ViewProviderSketch.

Definition at line 212 of file ViewProvider2DObject.cpp.

References createGrid(), App::PropertyBool::getValue(), GridRoot, GridSize, GridStyle, ShowGrid, and TightGrid.

bool ViewProvider2DObject::setEdit ( int  ModNum  )  [protected, virtual]

is called by the document when the provider goes in edit mode

Reimplemented from PartGui::ViewProviderPartExt.

Reimplemented in SketcherGui::ViewProviderSketch.

Definition at line 239 of file ViewProvider2DObject.cpp.

void ViewProvider2DObject::unsetEdit ( int  ModNum  )  [protected, virtual]

is called when you loose the edit mode

Reimplemented from PartGui::ViewProviderPartExt.

Reimplemented in SketcherGui::ViewProviderSketch.

Definition at line 244 of file ViewProvider2DObject.cpp.

void ViewProvider2DObject::updateData ( const App::Property  )  [virtual]

Member Data Documentation

SoSeparator* PartGui::ViewProvider2DObject::GridRoot [protected]

Definition at line 76 of file ViewProvider2DObject.h.

Referenced by createGrid(), onChanged(), updateData(), and ~ViewProvider2DObject().

Definition at line 58 of file ViewProvider2DObject.h.

Referenced by createGrid(), and onChanged().

const char * ViewProvider2DObject::GridStyleEnums = {"Dashed","Light",NULL} [static, protected]

Definition at line 82 of file ViewProvider2DObject.h.

Property to switch the grid on and off.

Definition at line 56 of file ViewProvider2DObject.h.

Referenced by attach(), onChanged(), SketcherGui::ViewProviderSketch::setEdit(), SketcherGui::ViewProviderSketch::unsetEdit(), and updateData().


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

Generated on Wed Nov 23 19:02:40 2011 for FreeCAD by  doxygen 1.6.1