General interface for all visual stuff in FreeCAD This class is used to generate and handle all around visualizing and presenting objects from the FreeCAD App layer to the user. More...
#include <ViewProvider.h>
Public Member Functions | |
virtual bool | canAddToSceneGraph () const |
Indicate whether to be added to scene graph or not. More... | |
virtual std::vector< App::DocumentObject * > | claimChildren3D (void) const |
deliver the children belonging to this object this method is used to deliver the objects to the 3DView which should be grouped under its scene graph. More... | |
SoSeparator * | getAnnotation (void) |
virtual SoSeparator * | getBackRoot (void) const |
virtual SoGroup * | getChildRoot (void) const |
virtual SoSeparator * | getFrontRoot (void) const |
SoSwitch * | getModeSwitch (void) const |
virtual SoSeparator * | getRoot (void) const |
SoTransform * | getTransformNode () const |
ViewProvider () | |
constructor. More... | |
virtual | ~ViewProvider () |
destructor. More... | |
Selection handling | |
This group of methods do the selection handling. Here you can define how the selection for your ViewProfider works. | |
virtual bool | useNewSelectionModel (void) const |
indicates if the ViewProvider use the new Selection model More... | |
virtual bool | isSelectable (void) const |
virtual bool | getElementPicked (const SoPickedPoint *, std::string &subname) const |
return a hit element given the picked point which contains the full node path More... | |
virtual std::string | getElement (const SoDetail *) const |
return a hit element to the selection path or 0 More... | |
virtual SoDetail * | getDetail (const char *) const |
return the coin node detail of the subelement More... | |
virtual bool | getDetailPath (const char *subname, SoFullPath *pPath, bool append, SoDetail *&det) const |
return the coin node detail and path to the node of the subelement More... | |
int | partialRender (const std::vector< std::string > &subelements, bool clear) |
partial rendering setup More... | |
virtual std::vector< Base::Vector3d > | getModelPoints (const SoPickedPoint *) const |
virtual std::vector< Base::Vector3d > | getSelectionShape (const char *Element) const |
return the highlight lines for a given element or the whole shape More... | |
Base::BoundBox3d | getBoundingBox (const char *subname=0, bool transform=true, MDIView *view=0) const |
Return the bound box of this view object. More... | |
virtual bool | onDelete (const std::vector< std::string > &subNames) |
Get called if the object is about to get deleted. More... | |
virtual void | beforeDelete () |
Called before deletion. More... | |
virtual bool | canDelete (App::DocumentObject *obj) const |
Asks the view provider if the given object that is part of its outlist can be removed from there without breaking it. More... | |
Drag and drop | |
To enable drag and drop you have to re-implement canDragObjects() and canDropObjects() to return true. For finer control you can also re-implement canDragObject() or canDropObject() to filter certain object types, by default these methods don't filter any types. To take action of drag and drop the method dragObject() and dropObject() must be re-implemented, too. | |
virtual bool | canDragObjects () const |
Check whether children can be removed from the view provider by drag and drop. More... | |
virtual bool | canDragObject (App::DocumentObject *) const |
Check whether the object can be removed from the view provider by drag and drop. More... | |
virtual void | dragObject (App::DocumentObject *) |
Remove a child from the view provider by drag and drop. More... | |
virtual bool | canDropObjects () const |
Check whether objects can be added to the view provider by drag and drop or drop only. More... | |
virtual bool | canDropObject (App::DocumentObject *) const |
Check whether the object can be dropped to the view provider by drag and drop or drop only. More... | |
virtual bool | canDragAndDropObject (App::DocumentObject *) const |
Return false to force drop only operation for a given object. More... | |
virtual void | dropObject (App::DocumentObject *) |
Add an object to the view provider by drag and drop. More... | |
virtual bool | canDropObjectEx (App::DocumentObject *obj, App::DocumentObject *owner, const char *subname, const std::vector< std::string > &elements) const |
Query object dropping with full quanlified name. More... | |
virtual std::string | getDropPrefix () const |
return a subname referencing the sub-object holding the dropped objects More... | |
virtual std::string | dropObjectEx (App::DocumentObject *obj, App::DocumentObject *owner, const char *subname, const std::vector< std::string > &elements) |
Add an object with full quanlified name to the view provider by drag and drop. More... | |
virtual int | replaceObject (App::DocumentObject *oldObj, App::DocumentObject *newObj) |
Replace an object to the view provider by drag and drop. More... | |
virtual bool | showInTree () const |
Tell the tree view if this object should appear there. More... | |
virtual bool | canRemoveChildrenFromRoot () const |
Tell the tree view to remove children items from the tree root. More... | |
Display mode methods | |
std::string | getActiveDisplayMode (void) const |
virtual void | setDisplayMode (const char *ModeName) |
set the display mode More... | |
virtual const char * | getDefaultDisplayMode () const |
get the default display mode More... | |
virtual std::vector< std::string > | getDisplayModes (void) const |
returns a list of all possible display modes More... | |
virtual void | hide (void) |
Hides the view provider. More... | |
virtual void | show (void) |
Shows the view provider. More... | |
virtual bool | isShow (void) const |
checks whether the view provider is visible or not More... | |
void | setVisible (bool) |
bool | isVisible () const |
void | setLinkVisible (bool) |
bool | isLinkVisible () const |
virtual void | setOverrideMode (const std::string &mode) |
Overrides the display mode with mode. More... | |
const std::string | getOverrideMode () |
Task panel | |
With this interface the ViewProvider can steer the appearance of widgets in the task view | |
virtual void | getTaskViewContent (std::vector< Gui::TaskView::TaskContent * > &) const |
get a list of TaskBoxes associated with this object More... | |
virtual bool | keyPressed (bool pressed, int key) |
is called when the provider is in edit and a key event occurs. Only ESC ends edit. More... | |
virtual bool | doubleClicked (void) |
is called by the tree if the user double click on the object More... | |
virtual bool | mouseMove (const SbVec2s &cursorPos, View3DInventorViewer *viewer) |
is called when the provider is in edit and the mouse is moved More... | |
virtual bool | mouseButtonPressed (int button, bool pressed, const SbVec2s &cursorPos, const View3DInventorViewer *viewer) |
is called when the Provider is in edit and the mouse is clicked More... | |
virtual void | setupContextMenu (QMenu *, QObject *, const char *) |
set up the context-menu with the supported edit modes More... | |
Public Member Functions inherited from App::TransactionalObject | |
virtual const char * | detachFromDocument () |
virtual bool | isAttachedToDocument () const |
TransactionalObject (void) | |
Constructor. More... | |
virtual | ~TransactionalObject () |
Public Member Functions inherited from App::ExtensionContainer | |
ExtensionIterator | extensionBegin () |
ExtensionContainer () | |
ExtensionIterator | extensionEnd () |
App::Extension * | getExtension (Base::Type, bool derived=true, bool no_except=false) const |
App::Extension * | getExtension (const std::string &name) const |
template<typename ExtensionT > | |
ExtensionT * | getExtensionByType (bool no_except=false, bool derived=true) const |
std::vector< Extension * > | getExtensionsDerivedFrom (Base::Type type) const |
template<typename ExtensionT > | |
std::vector< ExtensionT * > | getExtensionsDerivedFromType () const |
bool | hasExtension (Base::Type, bool derived=true) const |
bool | hasExtension (const std::string &name) const |
bool | hasExtensions () const |
void | registerExtension (Base::Type extension, App::Extension *ext) |
virtual | ~ExtensionContainer () |
virtual Property * | getPropertyByName (const char *name) const override |
find a property by its name More... | |
virtual const char * | getPropertyName (const Property *prop) const override |
get the name of a property More... | |
virtual void | getPropertyMap (std::map< std::string, Property * > &Map) const override |
get all properties of the class (including properties of the parent) More... | |
virtual void | getPropertyList (std::vector< Property * > &List) const override |
get all properties of the class (including properties of the parent) More... | |
virtual short | getPropertyType (const Property *prop) const override |
get the Type of a Property More... | |
virtual short | getPropertyType (const char *name) const override |
get the Type of a named Property More... | |
virtual const char * | getPropertyGroup (const Property *prop) const override |
get the Group of a Property More... | |
virtual const char * | getPropertyGroup (const char *name) const override |
get the Group of a named Property More... | |
virtual const char * | getPropertyDocumentation (const Property *prop) const override |
get the Group of a Property More... | |
virtual const char * | getPropertyDocumentation (const char *name) const override |
get the Group of a named Property More... | |
virtual void | Save (Base::Writer &writer) const override |
This method is used to save properties to an XML document. More... | |
void | saveExtensions (Base::Writer &writer) const |
void | restoreExtensions (Base::XMLReader &reader) |
Public Member Functions inherited from App::PropertyContainer | |
virtual App::Property * | addDynamicProperty (const char *type, const char *name=0, const char *group=0, const char *doc=0, short attr=0, bool ro=false, bool hidden=false) |
virtual App::Property * | getDynamicPropertyByName (const char *name) const |
DynamicProperty::PropData | getDynamicPropertyData (const Property *prop) const |
virtual std::vector< std::string > | getDynamicPropertyNames () const |
virtual std::string | getFullName () const |
virtual unsigned int | getMemSize (void) const |
This method is used to get the size of objects It is not meant to have the exact size, it is more or less an estimation which runs fast! Is it two bytes or a GB? More... | |
const char * | getPropertyPrefix () const |
bool | isHidden (const char *name) const |
check if the named property is hidden More... | |
bool | isHidden (const Property *prop) const |
check if the property is hidden More... | |
bool | isReadOnly (const char *name) const |
check if the named property is read-only More... | |
bool | isReadOnly (const Property *prop) const |
check if the property is read-only More... | |
virtual void | onPropertyStatusChanged (const Property &prop, unsigned long oldStatus) |
PropertyContainer () | |
A constructor. More... | |
virtual bool | removeDynamicProperty (const char *name) |
void | setPropertyPrefix (const char *prefix) |
void | setPropertyStatus (unsigned char bit, bool value) |
set the Status bit of all properties at once More... | |
virtual | ~PropertyContainer () |
A destructor. More... | |
Public Member Functions inherited from Base::Persistence | |
void | dumpToStream (std::ostream &stream, int compression) |
virtual Base::Type | getTypeId (void) const |
virtual void | RestoreDocFile (Reader &) |
This method is used to restore large amounts of data from a file In this method you simply stream in your SaveDocFile() saved data. More... | |
void | restoreFromStream (std::istream &stream) |
virtual void | SaveDocFile (Writer &) const |
This method is used to save large amounts of data to a binary file. More... | |
Public Member Functions inherited from Base::BaseClass | |
BaseClass () | |
Construction. More... | |
bool | isDerivedFrom (const Type type) const |
virtual void | setPyObject (PyObject *) |
virtual | ~BaseClass () |
Destruction. More... | |
Methods used by the Tree | |
If you want to take control over the viewprovider specific overlay icons, such as status, you can reimplement this method. | |
SoSeparator * | pcRoot |
The root Separator of the ViewProvider. More... | |
SoTransform * | pcTransform |
this is transformation for the provider More... | |
const char * | sPixmap |
SoSwitch * | pcModeSwitch |
this is the mode switch, all the different viewing modes are collected here More... | |
SoSeparator * | pcAnnotation |
The root separator for annotations. More... | |
ViewProviderPy * | pyViewObject |
std::string | overrideMode |
std::bitset< 32 > | StatusBits |
virtual QIcon | getIcon (void) const |
deliver the icon shown in the tree view More... | |
virtual std::vector< App::DocumentObject * > | claimChildren (void) const |
deliver the children belonging to this object this method is used to deliver the objects to the tree framework which should be grouped under its label. More... | |
virtual QIcon | mergeOverlayIcons (const QIcon &orig) const |
Signals of the view provider | |
boost::signals2::signal< void()> | signalChangeIcon |
signal on icon change More... | |
boost::signals2::signal< void(const QString &)> | signalChangeToolTip |
signal on tooltip change More... | |
boost::signals2::signal< void(const QString &)> | signalChangeStatusTip |
signal on status tip change More... | |
virtual void | update (const App::Property *) |
update the content of the ViewProvider this method have to implement the recalculation of the ViewProvider. More... | |
virtual void | updateData (const App::Property *) |
bool | isUpdatesEnabled () const |
void | setUpdatesEnabled (bool enable) |
unsigned long | getStatus () const |
return the status bits More... | |
bool | testStatus (ViewStatus pos) const |
void | setStatus (ViewStatus pos, bool on) |
std::string | toString () const |
PyObject * | getPyObject () |
This method returns the Python wrapper for a C++ object. More... | |
Color management methods | |
virtual std::map< std::string, App::Color > | getElementColors (const char *element=0) const |
virtual void | setElementColors (const std::map< std::string, App::Color > &colors) |
static const std::string & | hiddenMarker () |
static const char * | hasHiddenMarker (const char *subname) |
Edit methods | |
if the Viewprovider goes in edit mode you can handle most of the events in the viewer by yourself | |
enum | EditMode { Default = 0, Transform, Cutting, Color } |
virtual ViewProvider * | startEditing (int ModNum=0) |
bool | isEditing () const |
void | finishEditing () |
virtual void | setEditViewer (View3DInventorViewer *, int ModNum) |
adjust viewer settings when editing a view provider More... | |
virtual void | unsetEditViewer (View3DInventorViewer *) |
restores viewer settings when leaving editing mode More... | |
virtual bool | setEdit (int ModNum) |
is called by the document when the provider goes in edit mode More... | |
virtual void | unsetEdit (int ModNum) |
is called when you lose the edit mode More... | |
int | getEditingMode () const |
return the edit mode or -1 if nothing is being edited More... | |
direct handling methods | |
This group of methods is to direct influence the appearance of the viewed content. It's only for fast interactions! If you want to set the visual parameters you have to do it on the object viewed by this provider! | |
virtual void | setTransformation (const Base::Matrix4D &rcMatrix) |
set the viewing transformation of the provider More... | |
virtual void | setTransformation (const SbMatrix &rcMatrix) |
virtual MDIView * | getMDIView () const |
virtual void | Restore (Base::XMLReader &reader) |
This method is used to restore properties from an XML document. More... | |
bool | isRestoring () |
static SbMatrix | convert (const Base::Matrix4D &rcMatrix) |
static Base::Matrix4D | convert (const SbMatrix &sbMat) |
static void | eventCallback (void *ud, SoEventCallback *node) |
Display mask modes | |
Mainly controls an SoSwitch node which selects the display mask modes. The number of display mask modes doesn't necessarily match with the number of display modes. E.g. various display modes like Gaussian curvature, mean curvature or gray values are displayed by one display mask mode that handles color values. | |
void | addDisplayMaskMode (SoNode *node, const char *type) |
Adds a new display mask mode. More... | |
void | setDisplayMaskMode (const char *type) |
Activates the display mask mode type. More... | |
SoNode * | getDisplayMaskMode (const char *type) const |
Get the node to the display mask mode type. More... | |
std::vector< std::string > | getDisplayMaskModes () const |
Returns a list of added display mask modes. More... | |
void | setDefaultMode (int) |
int | getDefaultMode () const |
virtual void | setRenderCacheMode (int) |
bool | checkRecursion (SoNode *) |
Helper method to check that the node is valid, i.e. More... | |
SoPickedPoint * | getPointOnRay (const SbVec2s &pos, const View3DInventorViewer *viewer) const |
Helper method to get picked entities while editing. More... | |
SoPickedPoint * | getPointOnRay (const SbVec3f &pos, const SbVec3f &dir, const View3DInventorViewer *viewer) const |
Helper method to get picked entities while editing. More... | |
void | onBeforeChange (const App::Property *prop) |
Reimplemented from subclass. More... | |
void | onChanged (const App::Property *prop) |
Reimplemented from subclass. More... | |
Additional Inherited Members | |
Public Types inherited from App::ExtensionContainer | |
typedef std::map< Base::Type, App::Extension * >::iterator | ExtensionIterator |
Static Public Member Functions inherited from Base::Persistence | |
static void * | create (void) |
static std::string | encodeAttribute (const std::string &) |
Encodes an attribute upon saving. More... | |
static Base::Type | getClassTypeId (void) |
static void | init (void) |
Static Public Member Functions inherited from Base::BaseClass | |
static void * | create (void) |
static Type | getClassTypeId (void) |
static void | init (void) |
Protected Member Functions inherited from App::TransactionalObject | |
void | onBeforeChangeProperty (Document *doc, const Property *prop) |
Protected Member Functions inherited from App::PropertyContainer | |
virtual const PropertyData & | getPropertyData (void) const |
virtual void | handleChangedPropertyName (Base::XMLReader &reader, const char *TypeName, const char *PropName) |
PropertyContainer::handleChangedPropertyName is called during restore to possibly fix reading of older versions of this property container. More... | |
virtual void | handleChangedPropertyType (Base::XMLReader &reader, const char *TypeName, Property *prop) |
PropertyContainer::handleChangedPropertyType is called during restore to possibly fix reading of older versions of the property container. More... | |
Static Protected Member Functions inherited from App::PropertyContainer | |
static const PropertyData * | getPropertyDataPtr (void) |
Static Protected Member Functions inherited from Base::BaseClass | |
static void | initSubclass (Base::Type &toInit, const char *ClassName, const char *ParentName, Type::instantiationMethod method=nullptr) |
Protected Attributes inherited from App::PropertyContainer | |
DynamicProperty | dynamicProps |
Detailed Description
General interface for all visual stuff in FreeCAD This class is used to generate and handle all around visualizing and presenting objects from the FreeCAD App layer to the user.
This class and its descendents have to be implemented for any object type in order to show them in the 3DView and TreeView.
Member Enumeration Documentation
◆ EditMode
Constructor & Destructor Documentation
◆ ViewProvider()
ViewProvider::ViewProvider | ( | ) |
constructor.
References Gui::UpdateData.
◆ ~ViewProvider()
|
virtual |
destructor.
Reimplemented in PartDesignGui::ViewProvider.
References Base::PyObjectBase::DecRef(), pcAnnotation, pcModeSwitch, pcRoot, pcTransform, pyViewObject, and Base::PyObjectBase::setInvalid().
Member Function Documentation
◆ addDisplayMaskMode()
void ViewProvider::addDisplayMaskMode | ( | SoNode * | node, |
const char * | type | ||
) |
Adds a new display mask mode.
References pcModeSwitch.
Referenced by Gui::ViewProviderPy::addDisplayMode(), Gui::ViewProviderVRMLObject::attach(), PartDesignGui::ViewProviderDatum::attach(), Gui::ViewProviderPlacement::attach(), Gui::ViewProviderOriginFeature::attach(), PartGui::ViewProviderCurveNet::attach(), MeshGui::ViewProviderFace::attach(), MeshGui::ViewProviderMeshNode::attach(), InspectionGui::ViewProviderInspection::attach(), Gui::ViewProviderAnnotation::attach(), MeshGui::ViewProviderMeshTransform::attach(), FemGui::ViewProviderFemConstraint::attach(), MeshGui::ViewProviderMeshTransformDemolding::attach(), PartGui::ViewProviderPartReference::attach(), Gui::ViewProviderOrigin::attach(), FemGui::ViewProviderFemMesh::attach(), PartDesignGui::ViewProviderAddSub::attach(), Gui::ViewProviderInventorObject::attach(), FemGui::ViewProviderFemPostObject::attach(), Gui::ViewProviderMeasureDistance::attach(), PartGui::ViewProviderPartExt::attach(), Gui::ViewProviderAnnotationLabel::attach(), FemGui::ViewProviderFemPostFunction::attach(), MeshGui::ViewProviderMesh::attach(), Gui::ViewProviderLink::attach(), Gui::ViewProviderGeoFeatureGroupExtension::extensionAttach(), and Gui::ViewProviderExtern::setModeBySoInput().
◆ beforeDelete()
|
virtual |
Called before deletion.
Unlike onDelete(), this function is guaranteed to be called before deletion, either by Document::remObject(), or on document deletion.
Reimplemented in SpreadsheetGui::ViewProviderSheet.
Referenced by Gui::ViewProviderLink::onBeforeChange(), and Gui::Document::slotDeletedObject().
◆ canAddToSceneGraph()
|
virtual |
Indicate whether to be added to scene graph or not.
Referenced by Gui::View3DInventorViewer::addViewProvider(), and Gui::Document::toggleInSceneGraph().
◆ canDelete()
|
virtual |
Asks the view provider if the given object that is part of its outlist can be removed from there without breaking it.
- Parameters
-
obj is part of the outlist of the object associated to the view provider
- Returns
- true if the removal is approved by the view provider.
Reimplemented in Gui::ViewProviderLink, TechDrawGui::ViewProviderPage, Gui::ViewProviderDocumentObject, TechDrawGui::ViewProviderGeomHatch, TechDrawGui::ViewProviderHatch, TechDrawGui::ViewProviderDimension, TechDrawGui::ViewProviderViewSection, TechDrawGui::ViewProviderWeld, TechDrawGui::ViewProviderViewPart, TechDrawGui::ViewProviderBalloon, TechDrawGui::ViewProviderProjGroup, TechDrawGui::ViewProviderViewClip, TechDrawGui::ViewProviderProjGroupItem, TechDrawGui::ViewProviderTile, FemGui::ViewProviderFemAnalysis, TechDrawGui::ViewProviderLeader, and TechDrawGui::ViewProviderRichAnno.
Referenced by StdCmdDelete::activated().
◆ canDragAndDropObject()
|
virtual |
Return false to force drop only operation for a given object.
Reimplemented in Gui::ViewProviderLink, and PartDesignGui::ViewProviderSubShapeBinder.
Referenced by Gui::TreeWidget::dragMoveEvent(), and Gui::TreeWidget::dropEvent().
◆ canDragObject()
|
virtual |
Check whether the object can be removed from the view provider by drag and drop.
Reimplemented in Gui::ViewProviderLink, PartGui::ViewProviderMultiCommon, FemGui::ViewProviderFemAnalysis, PathGui::ViewProviderAreaView, PartGui::ViewProviderMultiFuse, PathGui::ViewProviderArea, PartGui::ViewProviderCompound, PathGui::ViewProviderPathShape, and PartGui::ViewProviderFace.
◆ canDragObjects()
|
virtual |
Check whether children can be removed from the view provider by drag and drop.
Reimplemented in Gui::ViewProviderLink, PartGui::ViewProviderMultiCommon, FemGui::ViewProviderFemAnalysis, Gui::ViewProviderOrigin, PathGui::ViewProviderAreaView, PartGui::ViewProviderMultiFuse, PathGui::ViewProviderArea, PartGui::ViewProviderCompound, PathGui::ViewProviderPathShape, PathGui::ViewProviderPathCompound, and PartGui::ViewProviderFace.
◆ canDropObject()
|
virtual |
Check whether the object can be dropped to the view provider by drag and drop or drop only.
Reimplemented in PartDesignGui::ViewProviderBody, FemGui::ViewProviderFemAnalysis, PartGui::ViewProviderMultiCommon, PathGui::ViewProviderAreaView, PartGui::ViewProviderMultiFuse, PathGui::ViewProviderArea, PartGui::ViewProviderCompound, PathGui::ViewProviderPathShape, and PartGui::ViewProviderFace.
References Base::Console(), and Base::ConsoleSingleton::Log().
Referenced by Gui::ViewProviderDocumentObject::canDropObjectEx(), and canDropObjectEx().
◆ canDropObjectEx()
|
virtual |
Query object dropping with full quanlified name.
Tree view now calls this function instead of canDropObject(), and may query for objects from other document. The default implementation (actually in ViewProviderDocumentObject) inhibites cross document dropping, and calls canDropObject(obj) for the rest. Override this function to enable cross document linking.
- Parameters
-
obj the object being dropped owner the (grand)parent object of the dropping object. Maybe null. This may not be the top parent object, as tree view will try to find a parent of the dropping object relative to this object to avoid cyclic dependency subname subname reference to the dropping object elements non-object sub-elements, e.g. Faces, Edges, selected when the object is being dropped
- Returns
- Return whether the dropping action is allowed.
Reimplemented in Gui::ViewProviderLink, PartDesignGui::ViewProviderSubShapeBinder, and Gui::ViewProviderDocumentObject.
References canDropObject().
◆ canDropObjects()
|
virtual |
Check whether objects can be added to the view provider by drag and drop or drop only.
Reimplemented in Gui::ViewProviderLink, PartDesignGui::ViewProviderSubShapeBinder, PartDesignGui::ViewProviderBody, FemGui::ViewProviderFemAnalysis, PartGui::ViewProviderMultiCommon, PathGui::ViewProviderAreaView, PartGui::ViewProviderMultiFuse, PathGui::ViewProviderArea, PartGui::ViewProviderCompound, PathGui::ViewProviderPathShape, PathGui::ViewProviderPathCompound, and PartGui::ViewProviderFace.
Referenced by Gui::TreeWidget::dragMoveEvent(), and Gui::TreeWidget::dropEvent().
◆ canRemoveChildrenFromRoot()
|
virtual |
Tell the tree view to remove children items from the tree root.
Referenced by Gui::DocumentObjectData::DocumentObjectData().
◆ checkRecursion()
Helper method to check that the node is valid, i.e.
it must not cause and infinite recursion.
References Gui::addNodes().
Referenced by Gui::ViewProviderVRMLObject::updateData().
◆ claimChildren()
|
virtual |
deliver the children belonging to this object this method is used to deliver the objects to the tree framework which should be grouped under its label.
Obvious is the usage in the group but it can be used for any kind of grouping needed for a special purpose.
Reimplemented in Gui::ViewProviderLink, PartDesignGui::ViewProviderSubShapeBinder, TechDrawGui::ViewProviderPage, PartGui::ViewProviderThickness, PartGui::ViewProviderOffset, PartGui::ViewProviderSweep, PartGui::ViewProviderLoft, PartGui::ViewProviderRevolution, TechDrawGui::ViewProviderViewPart, PartGui::ViewProviderMultiCommon, TechDrawGui::ViewProviderViewSection, TechDrawGui::ViewProviderViewClip, TechDrawGui::ViewProviderWeld, TechDrawGui::ViewProviderProjGroup, FemGui::ViewProviderFemAnalysis, FemGui::ViewProviderFemPostFunctionProvider, PathGui::ViewProviderAreaView, PartDesignGui::ViewProviderSketchBased, PartGui::ViewProviderBoolean, PartGui::ViewProviderExtrusion, PartDesignGui::ViewProviderHole, PartDesignGui::ViewProviderMainPart, PartDesignGui::ViewProviderLoft, PartDesignGui::ViewProviderPipe, PathGui::ViewProviderArea, FemGui::ViewProviderFemPostPipeline, PartGui::ViewProviderMultiFuse, RobotGui::ViewProviderTrajectoryDressUp, PartDesignGui::ViewProviderMultiTransform, PathGui::ViewProviderPathShape, RobotGui::ViewProviderTrajectoryCompound, PathGui::ViewProviderPathCompound, Gui::ViewProviderOrigin, TechDrawGui::ViewProviderLeader, FemGui::ViewProviderFemConstraint, PartGui::ViewProviderFace, PartGui::ViewProviderChamfer, PartGui::ViewProviderFillet, PartGui::ViewProviderRuledSurface, PartGui::ViewProviderMirror, and PartGui::ViewProviderCompound.
Referenced by Gui::Document::addRootObjectsToGroup(), Gui::ViewProviderPy::claimChildren(), FemGui::ViewProviderFemAnalysis::claimChildren(), Gui::ViewProviderGeoFeatureGroupExtension::extensionClaimChildren(), femviewprovider.view_result_mechanical.VPResultMechanical::onDelete(), BOPTools.SplitFeatures.ViewProviderBooleanFragments::onDelete(), BOPTools.JoinFeatures.ViewProviderConnect::onDelete(), femviewprovider.view_mesh_gmsh.VPMeshGmsh::onDelete(), BOPTools.SplitFeatures.ViewProviderSlice::onDelete(), BOPTools.SplitFeatures.ViewProviderXOR::onDelete(), and Gui::DocumentObjectData::updateChildren().
◆ claimChildren3D()
|
virtual |
deliver the children belonging to this object this method is used to deliver the objects to the 3DView which should be grouped under its scene graph.
This affects the visibility and the 3D position of the object.
Reimplemented in FemGui::ViewProviderFemPostFunctionProvider, FemGui::ViewProviderFemPostPipeline, and Gui::ViewProviderOrigin.
Referenced by Gui::LinkInfo::updateChildren().
◆ convert() [1/2]
|
static |
References Base::Matrix4D::getGLMatrix().
Referenced by PartDesignGui::ViewProviderTransformed::recomputeFeature(), and Gui::ViewProviderLink::updateDraggingPlacement().
◆ convert() [2/2]
|
static |
◆ doubleClicked()
|
virtual |
is called by the tree if the user double click on the object
Reimplemented in Gui::ViewProviderPart, PartDesignGui::ViewProvider, TechDrawGui::ViewProviderPage, TechDrawGui::ViewProviderGeomHatch, PartDesignGui::ViewProviderBody, TechDrawGui::ViewProviderHatch, Gui::ViewProviderDragger, SpreadsheetGui::ViewProviderSheet, PartDesignGui::ViewProviderDatum, SketcherGui::ViewProviderSketch, MeshGui::ViewProviderMesh, TechDrawGui::ViewProviderViewPart, Gui::ViewProviderAnnotationLabel, FemGui::ViewProviderFemPostFunction, TechDrawGui::ViewProviderBalloon, TechDrawGui::ViewProviderViewSection, TechDrawGui::ViewProviderWeld, TechDrawGui::ViewProviderProjGroup, FemGui::ViewProviderFemPostObject, TechDrawGui::ViewProviderProjGroupItem, FemGui::ViewProviderFemAnalysis, Gui::ViewProviderMaterialObject, RaytracingGui::ViewProviderLux, PartDesignGui::ViewProviderBase, RaytracingGui::ViewProviderPovray, FemGui::ViewProviderSetElements, FemGui::ViewProviderSetFaces, FemGui::ViewProviderSetGeometry, FemGui::ViewProviderSetNodes, RobotGui::ViewProviderEdge2TracObject, DrawingGui::ViewProviderDrawingPage, TechDrawGui::ViewProviderLeader, TechDrawGui::ViewProviderRichAnno, PartGui::ViewProviderPart, Gui::ViewProviderLink, PartDesignGui::ViewProviderSubShapeBinder, PartDesignGui::ViewProviderLoft, PartDesignGui::ViewProviderPipe, and Gui::ViewProviderTextDocument.
Referenced by Gui::ViewProviderLink::doubleClicked(), PartDesignGui::makeBody(), and Gui::TreeWidget::mouseDoubleClickEvent().
◆ dragObject()
|
virtual |
Remove a child from the view provider by drag and drop.
Reimplemented in Gui::ViewProviderLink, PartGui::ViewProviderMultiCommon, FemGui::ViewProviderFemAnalysis, PathGui::ViewProviderAreaView, PartGui::ViewProviderMultiFuse, PathGui::ViewProviderArea, PartGui::ViewProviderCompound, PathGui::ViewProviderPathShape, PathGui::ViewProviderPathCompound, and PartGui::ViewProviderFace.
Referenced by Gui::TreeWidget::dropEvent().
◆ dropObject()
|
virtual |
Add an object to the view provider by drag and drop.
Reimplemented in PartDesignGui::ViewProviderBody, FemGui::ViewProviderFemAnalysis, PartGui::ViewProviderMultiCommon, PathGui::ViewProviderAreaView, PartGui::ViewProviderMultiFuse, PathGui::ViewProviderArea, PartGui::ViewProviderCompound, PathGui::ViewProviderPathShape, PathGui::ViewProviderPathCompound, and PartGui::ViewProviderFace.
Referenced by dropObjectEx().
◆ dropObjectEx()
|
virtual |
Add an object with full quanlified name to the view provider by drag and drop.
- Parameters
-
obj the object being dropped owner the (grand)parent object of the dropping object. Maybe null. This may not be the top parent object, as tree view will try to find a parent of the dropping object relative to this object to avoid cyclic dependency subname subname reference to the dropping object elements non-object sub-elements, e.g. Faces, Edges, selected when the object is being dropped
- Returns
- Optionally returns a subname reference locating the dropped object, which may or may not be the actual dropped object, e.g. it may be a link.
Reimplemented in Gui::ViewProviderLink, and PartDesignGui::ViewProviderSubShapeBinder.
References dropObject().
Referenced by Gui::TreeWidget::dropEvent().
◆ eventCallback()
|
static |
References Gui::Application::activeDocument(), Base::Console(), Base::ConsoleSingleton::Error(), Gui::Application::Instance, Gui::Document::resetEdit(), and OfflineRenderingUtils::viewer().
Referenced by Gui::View3DInventorViewer::resetEditingViewProvider(), and Gui::View3DInventorViewer::setEditingViewProvider().
◆ finishEditing()
void ViewProvider::finishEditing | ( | ) |
References unsetEdit().
Referenced by MeshGui::ViewProviderMesh::clipMeshCallback(), PointsGui::ViewProviderPoints::clipPointsCallback(), MeshGui::ViewProviderMesh::partMeshCallback(), MeshGui::ViewProviderMesh::segmMeshCallback(), MeshGui::ViewProviderMesh::selectGLCallback(), and MeshGui::ViewProviderMesh::trimMeshCallback().
◆ getActiveDisplayMode()
std::string ViewProvider::getActiveDisplayMode | ( | void | ) | const |
◆ getAnnotation()
SoSeparator * ViewProvider::getAnnotation | ( | void | ) |
References pcAnnotation, and pcRoot.
Referenced by Gui::ViewProviderPy::getAnnotation().
◆ getBackRoot()
|
virtual |
◆ getBoundingBox()
Base::BoundBox3d ViewProvider::getBoundingBox | ( | const char * | subname = 0 , |
bool | transform = true , |
||
MDIView * | view = 0 |
||
) | const |
Return the bound box of this view object.
This method shall work regardless whether the current view object is visible or not.
References Gui::Application::activeDocument(), Gui::Application::activeView(), Base::BaseClass::getClassTypeId(), getDefaultMode(), getDetailPath(), Gui::Application::Instance, pcModeSwitch, pcRoot, and OfflineRenderingUtils::viewer().
Referenced by Gui::ViewProviderLink::initDraggingPlacement(), Gui::ViewProviderGeometryObject::updateData(), and FemGui::ViewProviderFemPostPipeline::updateFunctionSize().
◆ getChildRoot()
|
virtual |
◆ getDefaultDisplayMode()
|
virtual |
get the default display mode
Reimplemented in MeshGui::ViewProviderExport, MeshPartGui::ViewProviderCrossSections, PartGui::ViewProviderCrossSections, MeshGui::ViewProviderMeshCurvature, MeshGui::ViewProviderMeshTransformDemolding, MeshGui::ViewProviderMeshTransform, PartGui::ViewProvider2DObject, MeshGui::ViewProviderFace, and Gui::ViewProviderExtern.
Referenced by Gui::ViewProviderDocumentObject::attach().
◆ getDefaultMode()
int ViewProvider::getDefaultMode | ( | ) | const |
◆ getDetail()
|
virtual |
return the coin node detail of the subelement
Reimplemented in PathGui::ViewProviderPath, PartDesignGui::ViewProviderDatumCoordinateSystem, PartGui::ViewProviderPartExt, PartDesignGui::ViewProviderDatum, and FemGui::ViewProviderFemMesh.
Referenced by Gui::SoFCUnifiedSelection::doAction(), getDetailPath(), and MeshPartGui::CurveOnMeshHandler::Private::vertexCallback().
◆ getDetailPath()
|
virtual |
return the coin node detail and path to the node of the subelement
- Parameters
-
subname dot separated string reference to the sub element pPath output coin path leading to the returned element detail append If true, pPath will be first appended with the root node and the mode switch node of this view provider.
- Returns
- the coint detail of the subelement
If this view provider links to other view provider, then the implementation of getDetailPath() shall also append all intermediate nodes starting just after the mode switch node up till the mode switch of the linked view provider.
Reimplemented in Gui::ViewProviderDocumentObject, Gui::ViewProviderLink, and Gui::ViewProviderPlacement.
References getDetail(), pcModeSwitch, and pcRoot.
Referenced by Gui::SoFCUnifiedSelection::doAction(), getBoundingBox(), Gui::ViewProviderDocumentObject::getDetailPath(), and partialRender().
◆ getDisplayMaskMode()
SoNode * ViewProvider::getDisplayMaskMode | ( | const char * | type | ) | const |
Get the node to the display mask mode type.
References pcModeSwitch.
Referenced by Gui::Dialog::DlgInspector::setNodeNames().
◆ getDisplayMaskModes()
std::vector< std::string > ViewProvider::getDisplayMaskModes | ( | ) | const |
Returns a list of added display mask modes.
Referenced by Gui::Dialog::DlgInspector::setNodeNames().
◆ getDisplayModes()
|
virtual |
returns a list of all possible display modes
Reimplemented in Gui::ViewProviderLink, PartGui::ViewProviderPartExt, Gui::ViewProviderDocumentObjectGroup, TechDrawGui::ViewProviderGeomHatch, PartDesignGui::ViewProviderBody, TechDrawGui::ViewProviderDrawingView, TechDrawGui::ViewProviderPage, Gui::ViewProviderPlacement, PartDesignGui::ViewProviderDatum, TechDrawGui::ViewProviderHatch, TechDrawGui::ViewProviderTemplate, MeshGui::ViewProviderMesh, TechDrawGui::ViewProviderDimension, TechDrawGui::ViewProviderViewPart, Gui::ViewProviderAnnotationLabel, DrawingGui::ViewProviderDrawingClip, TechDrawGui::ViewProviderBalloon, MeshGui::ViewProviderExport, TechDrawGui::ViewProviderViewSection, MeshPartGui::ViewProviderCrossSections, FemGui::ViewProviderFemAnalysis, PartGui::ViewProviderCrossSections, TechDrawGui::ViewProviderWeld, Gui::ViewProviderMeasureDistance, TechDrawGui::ViewProviderAnnotation, TechDrawGui::ViewProviderSymbol, TechDrawGui::ViewProviderSpreadsheet, TechDrawGui::ViewProviderImage, TechDrawGui::ViewProviderViewClip, DrawingGui::ViewProviderDrawingView, TechDrawGui::ViewProviderProjGroup, TechDrawGui::ViewProviderTile, TechDrawGui::ViewProviderProjGroupItem, PointsGui::ViewProviderPoints, PartGui::ViewProviderRuledSurface, PartGui::ViewProviderPrism, PartGui::ViewProviderRegularPolygon, PartGui::ViewProviderHelixParametric, PartGui::ViewProviderSphereParametric, MeshGui::ViewProviderMeshCurvature, PartGui::ViewProviderWedge, Gui::ViewProviderOrigin, PartGui::ViewProviderPartReference, PartGui::ViewProviderEllipsoid, MeshGui::ViewProviderMeshTransformDemolding, PartGui::ViewProviderSpiralParametric, MeshGui::ViewProviderMeshTransform, InspectionGui::ViewProviderInspection, FemGui::ViewProviderFemConstraint, Gui::ViewProviderAnnotation, MeshGui::ViewProviderFace, PartGui::ViewProvider2DObject, FemGui::ViewProviderSolver, DrawingGui::ViewProviderDrawingPage, PartGui::ViewProviderCurveNet, Gui::ViewProviderExtern, PartGui::ViewProviderBox, PartGui::ViewProviderCircleParametric, PartGui::ViewProviderConeParametric, PartGui::ViewProviderCylinderParametric, PartGui::ViewProviderEllipseParametric, PartGui::ViewProviderLineParametric, PartGui::ViewProviderPlaneParametric, PartGui::ViewProviderPointParametric, PartGui::ViewProviderTorusParametric, SpreadsheetGui::ViewProviderSheet, FemGui::ViewProviderFemPostFunction, FemGui::ViewProviderFemPostObject, Gui::ViewProviderInventorObject, FemGui::ViewProviderFemMesh, PathGui::ViewProviderPath, MeshGui::ViewProviderMeshNode, Gui::ViewProviderOriginFeature, RobotGui::ViewProviderRobotObject, RobotGui::ViewProviderTrajectory, ImageGui::ViewProviderImagePlane, and Gui::ViewProviderVRMLObject.
Referenced by Gui::ViewProviderDocumentObject::attach(), Gui::FreeCADGui_subgraphFromObject(), Gui::ViewProviderLink::getDisplayModes(), and Gui::ViewProviderPy::listDisplayModes().
◆ getDropPrefix()
|
virtual |
return a subname referencing the sub-object holding the dropped objects
◆ getEditingMode()
|
protected |
return the edit mode or -1 if nothing is being edited
Referenced by PointsGui::ViewProviderPoints::clipPointsCallback(), isEditing(), MeshGui::ViewProviderMesh::partMeshCallback(), MeshGui::ViewProviderMesh::segmMeshCallback(), and MeshGui::ViewProviderMesh::selectGLCallback().
◆ getElement()
|
virtual |
return a hit element to the selection path or 0
Reimplemented in PartDesignGui::ViewProviderDatumCoordinateSystem, PartGui::ViewProviderPartExt, PartDesignGui::ViewProviderDatum, FemGui::ViewProviderFemMesh, and PathGui::ViewProviderPath.
Referenced by getElementPicked().
◆ getElementColors()
|
virtual |
Reimplemented in Gui::ViewProviderLink, and PartGui::ViewProviderPartExt.
Referenced by Gui::ElementColors::Private::addItem(), and Gui::ElementColors::Private::populate().
◆ getElementPicked()
|
virtual |
return a hit element given the picked point which contains the full node path
Reimplemented in Gui::ViewProviderPlacement, Gui::ViewProviderDocumentObject, and Gui::ViewProviderLink.
References getElement(), and isSelectable().
Referenced by Gui::ViewProviderDocumentObject::getElementPicked(), Gui::View3DInventorPy::getObjectInfo(), and Gui::View3DInventorPy::getObjectsInfo().
◆ getFrontRoot()
|
virtual |
◆ getIcon()
|
virtual |
deliver the icon shown in the tree view
Reimplemented in Gui::ViewProviderLink, Gui::ViewProviderDocumentObjectGroup, PartGui::ViewProviderMultiCommon, PartDesignGui::ViewProviderLoft, PathGui::ViewProviderPathShape, PartDesignGui::ViewProviderPipe, PartDesignGui::ViewProviderPrimitive, PartGui::ViewProviderBoolean, Gui::ViewProviderMaterialObject, PathGui::ViewProviderPathCompound, PartGui::ViewProviderMultiFuse, SurfaceGui::ViewProviderFilling, SurfaceGui::ViewProviderGeomFillSurface, SpreadsheetGui::ViewProviderSheet, MeshGui::ViewProviderMesh, InspectionGui::ViewProviderInspectionGroup, MeshGui::ViewProviderExport, PointsGui::ViewProviderPoints, MeshGui::ViewProviderMeshCurvature, PathGui::ViewProviderPath, InspectionGui::ViewProviderInspection, and MeshGui::ViewProviderMeshNode.
References Gui::BitmapFactory(), mergeOverlayIcons(), and sPixmap.
Referenced by PartGui::DlgExtrusion::findShapes(), PartGui::ViewProviderBoolean::getIcon(), Gui::ViewProviderPy::getIcon(), Gui::LinkInfo::getIcon(), TechDrawGui::TaskLinkDim::loadToTree(), Gui::DocumentObjectItem::testStatus(), ArchAxis.AxisSystemTaskPanel::update(), ArchSectionPlane.SectionPlaneTaskPanel::update(), and ArchComponent.ComponentTaskPanel::update().
◆ getMDIView()
|
virtual |
Reimplemented in TechDrawGui::ViewProviderPage, TechDrawGui::ViewProviderDrawingView, TechDrawGui::ViewProviderGeomHatch, SpreadsheetGui::ViewProviderSheet, TechDrawGui::ViewProviderHatch, TechDrawGui::ViewProviderTemplate, and Gui::ViewProviderTextDocument.
Referenced by TechDrawGui::ViewProviderHatch::getMDIView(), TechDrawGui::ViewProviderGeomHatch::getMDIView(), and Gui::Document::setActiveView().
◆ getModelPoints()
|
virtual |
Reimplemented in PartGui::ViewProviderPartExt.
Referenced by Gui::ManualAlignment::applyPickedProbe().
◆ getModeSwitch()
SoSwitch* Gui::ViewProvider::getModeSwitch | ( | void | ) | const |
Referenced by Gui::LinkInfo::getSnapshot().
◆ getOverrideMode()
const string ViewProvider::getOverrideMode | ( | ) |
References overrideMode.
Referenced by PartDesignGui::ViewProviderBody::onChanged().
◆ getPointOnRay() [1/2]
|
protected |
Helper method to get picked entities while editing.
It's in the responsibility of the caller to delete the returned instance.
References OfflineRenderingUtils::viewer().
◆ getPointOnRay() [2/2]
|
protected |
Helper method to get picked entities while editing.
It's in the responsibility of the caller to delete the returned instance.
References OfflineRenderingUtils::viewer().
◆ getPyObject()
|
virtual |
This method returns the Python wrapper for a C++ object.
It's in the responsibility of the programmer to do the correct reference counting. Basically there are two ways how to implement that: Either always return a new Python object then reference counting is not a matter or return always the same Python object then the reference counter must be incremented by one. However, it's absolutely forbidden to return always the same Python object without incrementing the reference counter.
The default implementation returns 'None'.
Reimplemented from Base::BaseClass.
Reimplemented in PartDesignGui::ViewProvider, Gui::ViewProviderLink, Gui::ViewProviderDocumentObject, MeshGui::ViewProviderMesh, and FemGui::ViewProviderFemMesh.
References Base::PyObjectBase::IncRef(), and pyViewObject.
Referenced by Gui::DocumentPy::activeObject(), Gui::DocumentPy::getActiveObject(), Gui::DocumentPy::getInEdit(), and Gui::DocumentPy::getObject().
◆ getRoot()
|
virtual |
Reimplemented in MeshGui::ViewProviderExport.
Referenced by Gui::Document::addViewProvider(), Gui::View3DInventorViewer::addViewProvider(), Gui::View3DInventorViewer::containsViewProvider(), Gui::SoFCUnifiedSelection::doAction(), Gui::FreeCADGui_subgraphFromObject(), Gui::ViewProviderGeometryObject::getPickedPoint(), Gui::ViewProviderGeometryObject::getPickedPoints(), Gui::View3DInventorViewer::getPointOnRay(), PartDesignGui::ViewProviderDatum::getRelevantBoundBox(), Gui::ViewProviderPy::getRootNode(), Gui::LinkInfo::getSnapshot(), Gui::Document::getViewOfViewProvider(), PartGui::TaskCheckGeometryResults::goCheck(), PartGui::FaceColors::Private::isVisibleFace(), Gui::ViewProviderDocumentObject::onChanged(), Gui::View3DInventorViewer::removeViewProvider(), Gui::View3DInventorViewer::resetEditingRoot(), Gui::Dialog::DlgInspector::setNodeNames(), Gui::View3DInventorViewer::setupEditingRoot(), Gui::Application::sExport(), Gui::Document::slotNewObject(), Gui::Document::slotTransactionRemove(), Gui::Document::toggleInSceneGraph(), PartGui::ViewProviderCustom::updateData(), SketcherGui::ViewProviderCustom::updateData(), PartDesignGui::ViewProviderBody::updateOriginDatumSize(), and Gui::ViewProviderOriginGroupExtension::updateOriginSize().
◆ getSelectionShape()
|
virtual |
return the highlight lines for a given element or the whole shape
Reimplemented in PartGui::ViewProviderPartExt, and FemGui::ViewProviderFemMesh.
◆ getStatus()
unsigned long Gui::ViewProvider::getStatus | ( | ) | const |
return the status bits
◆ getTaskViewContent()
|
virtual |
get a list of TaskBoxes associated with this object
Reimplemented in Gui::ViewProviderDocumentObject.
◆ getTransformNode()
SoTransform* Gui::ViewProvider::getTransformNode | ( | ) | const |
◆ hasHiddenMarker()
|
static |
References App::DocumentObject::hasHiddenMarker().
Referenced by partialRender().
◆ hiddenMarker()
|
static |
References App::DocumentObject::hiddenMarker().
Referenced by Gui::ViewProviderLink::applyColors(), Gui::ViewProviderLink::getElementColors(), and partialRender().
◆ hide()
|
virtual |
Hides the view provider.
Reimplemented in Gui::ViewProviderDocumentObject, TechDrawGui::ViewProviderDrawingView, TechDrawGui::ViewProviderPage, TechDrawGui::ViewProviderTemplate, DrawingGui::ViewProviderDrawingClip, FemGui::ViewProviderFemAnalysis, TechDrawGui::ViewProviderViewClip, FemGui::ViewProviderFemPostObject, DrawingGui::ViewProviderDrawingView, MeshGui::ViewProviderMeshCurvature, InspectionGui::ViewProviderInspection, and DrawingGui::ViewProviderDrawingPage.
References pcModeSwitch.
Referenced by DrawingGui::DrawingView::closeEvent(), TechDrawGui::MDIViewPage::closeEvent(), Gui::ViewProviderPy::hide(), Gui::ViewProviderDocumentObject::hide(), Mod.Show.mTempoVis.TempoVis::hide_all_dependencies(), Mod.Show.mTempoVis.TempoVis::hide_all_dependent(), Gui::Application::hideViewProvider(), Gui::MergeDocuments::importObject(), PartDesignGui::ViewProvider::makeTemporaryVisible(), Gui::ViewProviderDocumentObject::setActiveMode(), PartGui::DlgFilletEdges::setupFillet(), setVisible(), update(), and Gui::ViewProviderDocumentObject::updateView().
◆ isEditing()
bool ViewProvider::isEditing | ( | ) | const |
References getEditingMode().
Referenced by Gui::TreeWidget::contextMenuEvent().
◆ isLinkVisible()
bool ViewProvider::isLinkVisible | ( | ) | const |
◆ isRestoring()
bool Gui::ViewProvider::isRestoring | ( | ) |
References Gui::isRestoring.
Referenced by Gui::ViewProviderDocumentObject::attach(), Gui::ViewProviderLink::onChanged(), PartDesignGui::ViewProviderBody::slotChangedObjectApp(), PartDesignGui::ViewProviderBody::unifyVisualProperty(), Gui::ViewProviderDocumentObject::update(), Gui::LinkInfo::update(), and Gui::ViewProviderLink::updateData().
◆ isSelectable()
|
virtual |
Reimplemented in Gui::ViewProviderLink, Gui::ViewProviderPlacement, PartDesignGui::ViewProviderDatum, SketcherGui::ViewProviderSketch, and Gui::ViewProviderGeometryObject.
Referenced by Gui::SoFCUnifiedSelection::doAction(), Gui::ViewProviderDocumentObject::getElementPicked(), getElementPicked(), Gui::LinkInfo::getElementPicked(), Gui::View3DInventorPy::getObjectInfo(), and Gui::View3DInventorPy::getObjectsInfo().
◆ isShow()
|
virtual |
checks whether the view provider is visible or not
Reimplemented in Gui::ViewProviderDocumentObjectGroup, SpreadsheetGui::ViewProviderSheet, TechDrawGui::ViewProviderDrawingView, TechDrawGui::ViewProviderPage, TechDrawGui::ViewProviderTemplate, DrawingGui::ViewProviderDrawingClip, TechDrawGui::ViewProviderViewClip, FemGui::ViewProviderFemAnalysis, DrawingGui::ViewProviderDrawingView, Gui::ViewProviderMaterialObject, FemGui::ViewProviderResult, FemGui::ViewProviderSolver, and Gui::ViewProviderTextDocument.
References pcModeSwitch.
Referenced by PartGui::ViewProviderPartExt::forceUpdate(), Gui::Document::isShow(), isVisible(), PartDesignGui::ViewProvider::onDelete(), Gui::SelectionSingleton::setVisible(), Gui::DocumentObjectItem::testStatus(), update(), and Gui::ViewProviderDocumentObject::updateView().
◆ isUpdatesEnabled()
bool ViewProvider::isUpdatesEnabled | ( | ) | const |
References testStatus(), and Gui::UpdateData.
Referenced by update().
◆ isVisible()
bool ViewProvider::isVisible | ( | ) | const |
◆ keyPressed()
is called when the provider is in edit and a key event occurs. Only ESC ends edit.
Reimplemented in SketcherGui::ViewProviderSketch.
◆ mergeOverlayIcons()
|
protectedvirtual |
Reimplemented in PartDesignGui::ViewProvider.
Referenced by Gui::ViewProviderDocumentObjectGroup::getIcon(), getIcon(), and PartDesignGui::ViewProvider::mergeOverlayIcons().
◆ mouseButtonPressed()
|
virtual |
is called when the Provider is in edit and the mouse is clicked
Reimplemented in SketcherGui::ViewProviderSketch.
References OfflineRenderingUtils::viewer().
◆ mouseMove()
|
virtual |
is called when the provider is in edit and the mouse is moved
Reimplemented in SketcherGui::ViewProviderSketch.
References OfflineRenderingUtils::viewer().
◆ onBeforeChange()
|
protectedvirtual |
Reimplemented from subclass.
Reimplemented from App::PropertyContainer.
Reimplemented in Gui::ViewProviderDocumentObject, and Gui::ViewProviderLink.
References Gui::Application::Instance, App::PropertyContainer::onBeforeChange(), and Gui::Application::signalBeforeChangeObject.
Referenced by Gui::ViewProviderDocumentObject::onBeforeChange().
◆ onChanged()
|
protectedvirtual |
Reimplemented from subclass.
Reimplemented from App::ExtensionContainer.
Reimplemented in Gui::ViewProviderLink, Gui::ViewProviderDocumentObject, PartGui::ViewProviderPartExt, PartDesignGui::ViewProviderBoolean, Gui::ViewProviderPart, PartDesignGui::ViewProvider, TechDrawGui::ViewProviderPage, PartDesignGui::ViewProviderBody, Gui::ViewProviderPlacement, TechDrawGui::ViewProviderDrawingView, TechDrawGui::ViewProviderGeomHatch, TechDrawGui::ViewProviderHatch, TechDrawGui::ViewProviderTemplate, SketcherGui::ViewProviderSketch, MeshGui::ViewProviderMesh, FemGui::ViewProviderFemMesh, FemGui::ViewProviderFemPostFunction, Gui::ViewProviderAnnotationLabel, TechDrawGui::ViewProviderViewPart, TechDrawGui::ViewProviderProjGroup, TechDrawGui::ViewProviderViewSection, Gui::ViewProviderOrigin, Gui::ViewProviderMeasureDistance, PointsGui::ViewProviderPoints, MeshGui::ViewProviderMeshCurvature, Gui::ViewProviderGeometryObject, PathGui::ViewProviderPath, TechDrawGui::ViewProviderImage, FemGui::ViewProviderFemPostFunctionProvider, PartGui::ViewProviderSpline, FemGui::ViewProviderFemPostObject, PartDesignGui::ViewProviderDatumPoint, PartGui::ViewProviderCustom, PartGui::ViewProviderPartReference, SketcherGui::ViewProviderCustom, InspectionGui::ViewProviderInspection, MeshGui::ViewProviderMeshNode, FemGui::ViewProviderFemConstraint, PartGui::ViewProvider2DObject, Gui::ViewProviderAnnotation, Gui::ViewProviderOriginFeature, MeshGui::ViewProviderMeshDefects, RobotGui::ViewProviderRobotObject, Gui::ViewProviderTextDocument, TechDrawGui::ViewProviderDimension, TechDrawGui::ViewProviderBalloon, TechDrawGui::ViewProviderWeld, TechDrawGui::ViewProviderLeader, TechDrawGui::ViewProviderRichAnno, and PartDesignGui::ViewProviderDatumCoordinateSystem.
References Gui::Application::Instance, App::ExtensionContainer::onChanged(), and Gui::Application::signalChangedObject.
Referenced by draftviewproviders.view_base.ViewProviderDraft::attach(), ArchSite.Compass::buildCoordinates(), draftobjects.wire.Wire::execute(), ArchAxis.CommandArchGrid::IsActive(), Gui::ViewProviderDocumentObject::onChanged(), draftviewproviders.view_wpproxy.ViewProviderWorkingPlaneProxy::updateData(), draftviewproviders.view_label.ViewProviderLabel::updateData(), DraftLayer.ViewProviderLayer::updateData(), ArchBuildingPart.ViewProviderBuildingPart::updateData(), ArchPanel.ViewProviderPanelCut::updateData(), and ArchPanel.ViewProviderPanelSheet::updateData().
◆ onDelete()
|
virtual |
Get called if the object is about to get deleted.
Here you can delete other objects, switch their visibility or prevent the deletion of the object.
- Parameters
-
subNames list of selected subelements
- Returns
- true if the deletion is approved by the view provider.
Reimplemented in PartDesignGui::ViewProviderHole, Gui::ViewProviderLink, PartDesignGui::ViewProvider, PartDesignGui::ViewProviderBoolean, TechDrawGui::ViewProviderPage, PartDesignGui::ViewProviderTransformed, PartDesignGui::ViewProviderBody, TechDrawGui::ViewProviderTemplate, PartDesignGui::ViewProviderDatum, SketcherGui::ViewProviderSketch, PartGui::ViewProviderThickness, PartGui::ViewProviderOffset, PartGui::ViewProviderSweep, PartGui::ViewProviderLoft, PartGui::ViewProviderRevolution, PartGui::ViewProviderChamfer, PartGui::ViewProviderMultiCommon, TechDrawGui::ViewProviderWeld, TechDrawGui::ViewProviderViewPart, TechDrawGui::ViewProviderProjGroup, Gui::ViewProviderOrigin, TechDrawGui::ViewProviderProjGroupItem, FemGui::ViewProviderFemAnalysis, PartGui::ViewProviderFillet, PartGui::ViewProviderRuledSurface, PathGui::ViewProviderAreaView, PartGui::ViewProviderBoolean, PartDesignGui::ViewProviderLoft, PartDesignGui::ViewProviderPipe, PartDesignGui::ViewProviderSketchBased, PartGui::ViewProviderMultiFuse, PathGui::ViewProviderArea, PartGui::ViewProviderMirror, PartGui::ViewProviderCompound, PartDesignGui::ViewProviderMultiTransform, PathGui::ViewProviderPathShape, Gui::ViewProviderOriginFeature, DrawingGui::ViewProviderDrawingPage, and TechDrawGui::ViewProviderLeader.
Referenced by StdCmdDelete::activated(), SketcherGui::ElementView::deleteSelectedItems(), SketcherGui::ConstraintView::deleteSelectedItems(), SketcherGui::ViewProviderSketch::onDelete(), and Gui::Document::slotDeletedObject().
◆ partialRender()
int ViewProvider::partialRender | ( | const std::vector< std::string > & | subelements, |
bool | clear | ||
) |
partial rendering setup
- Parameters
-
subelements a list of dot separated string refer to the sub element clear if true, remove the the subelement from partial rendering. If else, add the subelement for rendering.
- Returns
- Return the number of subelement found
Partial rendering only works if there is at least one SoFCSelectRoot node in this view provider
References Gui::SoSelectionElementAction::Append, getDetailPath(), hasHiddenMarker(), hiddenMarker(), Gui::SoSelectionElementAction::Hide, pcModeSwitch, Gui::SoSelectionElementAction::Remove, and Gui::SoSelectionElementAction::Show.
Referenced by Gui::ElementColors::leaveEvent().
◆ replaceObject()
|
virtual |
Replace an object to the view provider by drag and drop.
- Parameters
-
oldObj object to be replaced newObj object to replace with
- Returns
- Returns 0 if not found, 1 if succeeded, -1 if not supported
Reimplemented in Gui::ViewProviderDocumentObject.
Referenced by Gui::ViewProviderDocumentObject::replaceObject().
◆ Restore()
|
virtual |
This method is used to restore properties from an XML document.
It uses the XMLReader class, which bases on SAX, to read the in Save() written information. Again the Vector as an example:
Reimplemented from App::ExtensionContainer.
Reimplemented in PartGui::ViewProvider2DObject.
Referenced by Gui::Document::importObjects(), PartGui::ViewProvider2DObject::Restore(), and Gui::Document::RestoreDocFile().
◆ setDefaultMode()
void ViewProvider::setDefaultMode | ( | int | val | ) |
◆ setDisplayMaskMode()
void ViewProvider::setDisplayMaskMode | ( | const char * | type | ) |
Activates the display mask mode type.
Referenced by FemGui::ViewProviderFemPostObject::attach(), FemGui::ViewProviderFemPostFunction::attach(), Gui::ViewProviderLink::attach(), Gui::ViewProviderGeoFeatureGroupExtension::extensionSetDisplayMode(), PartDesignGui::ViewProviderBody::onChanged(), Gui::ViewProviderVRMLObject::setDisplayMode(), PartGui::ViewProviderCurveNet::setDisplayMode(), Gui::ViewProviderOriginFeature::setDisplayMode(), Gui::ViewProviderPlacement::setDisplayMode(), PartDesignGui::ViewProviderDatum::setDisplayMode(), MeshPartGui::ViewProviderCurveOnMesh::setDisplayMode(), MeshGui::ViewProviderFace::setDisplayMode(), MeshGui::ViewProviderMeshNode::setDisplayMode(), InspectionGui::ViewProviderInspection::setDisplayMode(), MeshGui::ViewProviderMeshTransform::setDisplayMode(), Gui::ViewProviderAnnotation::setDisplayMode(), FemGui::ViewProviderFemConstraint::setDisplayMode(), MeshGui::ViewProviderMeshTransformDemolding::setDisplayMode(), PartGui::ViewProviderPartReference::setDisplayMode(), Gui::ViewProviderOrigin::setDisplayMode(), FemGui::ViewProviderFemMesh::setDisplayMode(), Gui::ViewProviderInventorObject::setDisplayMode(), Gui::ViewProviderMeasureDistance::setDisplayMode(), PartGui::ViewProviderPartExt::setDisplayMode(), Gui::ViewProviderAnnotationLabel::setDisplayMode(), MeshGui::ViewProviderMesh::setDisplayMode(), Gui::ViewProviderExtern::setModeBySoInput(), and PartDesignGui::ViewProviderAddSub::setPreviewDisplayMode().
◆ setDisplayMode()
|
virtual |
set the display mode
If you add new viewing modes in getDisplayModes() then you need to reimplement also seDisplaytMode() to handle these new modes by setting the appropriate display mode.
Reimplemented in PartGui::ViewProviderPartExt, PartDesignGui::ViewProviderBody, TechDrawGui::ViewProviderGeomHatch, TechDrawGui::ViewProviderDrawingView, Gui::ViewProviderPlacement, PartDesignGui::ViewProviderDatum, TechDrawGui::ViewProviderPage, SpreadsheetGui::ViewProviderSheet, TechDrawGui::ViewProviderHatch, TechDrawGui::ViewProviderTemplate, MeshGui::ViewProviderMesh, TechDrawGui::ViewProviderDimension, Gui::ViewProviderAnnotationLabel, TechDrawGui::ViewProviderViewPart, DrawingGui::ViewProviderDrawingClip, TechDrawGui::ViewProviderBalloon, TechDrawGui::ViewProviderViewSection, Gui::ViewProviderMeasureDistance, TechDrawGui::ViewProviderWeld, TechDrawGui::ViewProviderAnnotation, TechDrawGui::ViewProviderSymbol, TechDrawGui::ViewProviderSpreadsheet, TechDrawGui::ViewProviderImage, TechDrawGui::ViewProviderViewClip, DrawingGui::ViewProviderDrawingView, FemGui::ViewProviderFemPostObject, TechDrawGui::ViewProviderProjGroup, TechDrawGui::ViewProviderTile, Gui::ViewProviderInventorObject, PointsGui::ViewProviderPoints, TechDrawGui::ViewProviderProjGroupItem, FemGui::ViewProviderFemMesh, Gui::ViewProviderOrigin, MeshGui::ViewProviderMeshCurvature, PartGui::ViewProviderPartReference, PathGui::ViewProviderPath, MeshGui::ViewProviderMeshTransformDemolding, FemGui::ViewProviderFemConstraint, Gui::ViewProviderAnnotation, MeshGui::ViewProviderMeshTransform, InspectionGui::ViewProviderInspection, MeshGui::ViewProviderMeshNode, MeshGui::ViewProviderFace, MeshPartGui::ViewProviderCurveOnMesh, Gui::ViewProviderOriginFeature, DrawingGui::ViewProviderDrawingPage, PartGui::ViewProviderCurveNet, RobotGui::ViewProviderRobotObject, RobotGui::ViewProviderTrajectory, ImageGui::ViewProviderImagePlane, and Gui::ViewProviderVRMLObject.
Referenced by Gui::FreeCADGui_subgraphFromObject(), Gui::ViewProviderDocumentObject::setActiveMode(), Gui::ViewProviderVRMLObject::setDisplayMode(), ImageGui::ViewProviderImagePlane::setDisplayMode(), RobotGui::ViewProviderTrajectory::setDisplayMode(), RobotGui::ViewProviderRobotObject::setDisplayMode(), Gui::ViewProviderOriginFeature::setDisplayMode(), Gui::ViewProviderPlacement::setDisplayMode(), Gui::ViewProviderAnnotation::setDisplayMode(), Gui::ViewProviderOrigin::setDisplayMode(), Gui::ViewProviderInventorObject::setDisplayMode(), Gui::ViewProviderMeasureDistance::setDisplayMode(), and Gui::ViewProviderAnnotationLabel::setDisplayMode().
◆ setEdit()
|
protectedvirtual |
is called by the document when the provider goes in edit mode
Reimplemented in Gui::ViewProviderOriginFeature, MeshGui::ViewProviderMeshNode, Gui::ViewProviderLink, PartGui::ViewProviderPartExt, PartDesignGui::ViewProviderDatum, TechDrawGui::ViewProviderPage, PartDesignGui::ViewProviderBoolean, PartDesignGui::ViewProvider, PartDesignGui::ViewProviderSubShapeBinder, PartDesignGui::ViewProviderShapeBinder, PartDesignGui::ViewProviderTransformed, Gui::ViewProviderDragger, SpreadsheetGui::ViewProviderSheet, TechDrawGui::ViewProviderGeomHatch, TechDrawGui::ViewProviderHatch, SketcherGui::ViewProviderSketch, PartGui::ViewProviderThickness, PartGui::ViewProviderOffset, MeshGui::ViewProviderMesh, FemGui::ViewProviderFemAnalysis, FemGui::ViewProviderFemPostFunction, PartGui::ViewProviderChamfer, Gui::ViewProviderAnnotationLabel, TechDrawGui::ViewProviderViewPart, TechDrawGui::ViewProviderProjGroup, TechDrawGui::ViewProviderBalloon, TechDrawGui::ViewProviderViewSection, TechDrawGui::ViewProviderProjGroupItem, TechDrawGui::ViewProviderWeld, PartGui::ViewProviderFillet, FemGui::ViewProviderFemPostObject, FemGui::ViewProviderFemConstraintTransform, PartDesignGui::ViewProviderPipe, PartDesignGui::ViewProviderLoft, PointsGui::ViewProviderPoints, FemGui::ViewProviderFemConstraintContact, FemGui::ViewProviderFemConstraintDisplacement, FemGui::ViewProviderFemConstraintHeatflux, FemGui::ViewProviderFemConstraintInitialTemperature, FemGui::ViewProviderFemConstraintPlaneRotation, FemGui::ViewProviderFemConstraintTemperature, PartDesignGui::ViewProviderPrimitive, FemGui::ViewProviderFemMeshShapeNetgen, FemGui::ViewProviderFemConstraintBearing, FemGui::ViewProviderFemConstraintFixed, FemGui::ViewProviderFemConstraintFluidBoundary, FemGui::ViewProviderFemConstraintForce, FemGui::ViewProviderFemConstraintGear, FemGui::ViewProviderFemConstraintPulley, PartDesignGui::ViewProviderHole, PartGui::ViewProviderMirror, PathGui::ViewProviderPathCompound, RaytracingGui::ViewProviderLux, PartDesignGui::ViewProviderBase, FemGui::ViewProviderFemConstraintPressure, RaytracingGui::ViewProviderPovray, RobotGui::ViewProviderTrajectoryDressUp, RobotGui::ViewProviderTrajectoryCompound, PartDesignGui::ViewProviderDressUp, FemGui::ViewProviderSetElements, FemGui::ViewProviderSetFaces, FemGui::ViewProviderSetGeometry, FemGui::ViewProviderSetNodes, RobotGui::ViewProviderEdge2TracObject, FemGui::ViewProviderFemConstraint, DrawingGui::ViewProviderDrawingPage, PartGui::ViewProvider2DObject, PartGui::ViewProviderCurveNet, TechDrawGui::ViewProviderLeader, TechDrawGui::ViewProviderRichAnno, SurfaceGui::ViewProviderFilling, PartGui::ViewProviderImport, and SurfaceGui::ViewProviderGeomFillSurface.
Referenced by PathScripts.PathSetupSheetGui.ViewProvider::doubleClicked(), PathScripts.PathToolBitGui.ViewProvider::doubleClicked(), ArchReference.ViewProviderArchReference::doubleClicked(), Spreadsheet_legacy.ViewProviderSpreadsheet::doubleClicked(), ArchAxis.ViewProviderArchGrid::doubleClicked(), ArchSchedule.CommandArchSchedule::IsActive(), ArchAxis.CommandArchGrid::IsActive(), TechDrawGui::ViewProviderRichAnno::setEdit(), TechDrawGui::ViewProviderLeader::setEdit(), TechDrawGui::ViewProviderPage::setEdit(), TechDrawGui::ViewProviderWeld::setEdit(), TechDrawGui::ViewProviderViewSection::setEdit(), TechDrawGui::ViewProviderBalloon::setEdit(), TechDrawGui::ViewProviderViewPart::setEdit(), FemGui::ViewProviderFemAnalysis::setEdit(), Gui::ViewProviderLink::setEdit(), PathScripts.PathIconViewProvider.ViewProvider::setupContextMenu(), PathScripts.PathToolControllerGui.ViewProvider::setupContextMenu(), PathScripts.PathOpGui.ViewProvider::setupContextMenu(), PathScripts.PathJobGui.ViewProvider::setupContextMenu(), and startEditing().
◆ setEditViewer()
|
virtual |
adjust viewer settings when editing a view provider
Reimplemented in Gui::ViewProviderLink, Gui::ViewProviderDragger, and SketcherGui::ViewProviderSketch.
Referenced by Gui::View3DInventorViewer::setEditingViewProvider().
◆ setElementColors()
|
virtual |
Reimplemented in Gui::ViewProviderLink.
Referenced by Gui::ElementColors::Private::apply().
◆ setLinkVisible()
void ViewProvider::setLinkVisible | ( | bool | visible | ) |
◆ setOverrideMode()
|
virtual |
Overrides the display mode with mode.
Reimplemented in Gui::ViewProviderLink, and PartDesignGui::ViewProviderBody.
References overrideMode, and pcModeSwitch.
Referenced by Gui::View3DInventorViewer::addViewProvider(), PartDesignGui::ViewProviderBody::onChanged(), PartDesignGui::ViewProviderBody::setOverrideMode(), and Gui::ViewProviderLink::setOverrideMode().
◆ setRenderCacheMode()
|
virtual |
References pcRoot.
◆ setStatus()
void Gui::ViewProvider::setStatus | ( | ViewStatus | pos, |
bool | on | ||
) |
Referenced by Gui::Document::addViewProvider(), Gui::ViewProviderDocumentObject::detachFromDocument(), Gui::Document::importObjects(), setUpdatesEnabled(), Gui::Document::slotFinishRestoreObject(), Gui::Document::slotNewObject(), PartDesignGui::ViewProviderDatumPoint::ViewProviderDatumPoint(), DrawingGui::ViewProviderDrawingClip::ViewProviderDrawingClip(), DrawingGui::ViewProviderDrawingView::ViewProviderDrawingView(), PartDesignGui::ViewProviderShapeBinder::ViewProviderShapeBinder(), TechDrawGui::ViewProviderTemplate::ViewProviderTemplate(), and TechDrawGui::ViewProviderViewClip::ViewProviderViewClip().
◆ setTransformation() [1/2]
|
virtual |
set the viewing transformation of the provider
References Base::Matrix4D::getGLMatrix(), and pcTransform.
Referenced by Gui::Dialog::TransformStrategy::acceptDataTransform(), Gui::Dialog::TransformStrategy::applyViewTransform(), Gui::ViewProviderGeoFeatureGroupExtension::extensionUpdateData(), Gui::Dialog::TransformStrategy::resetViewTransform(), Gui::Document::setPos(), Gui::ViewProviderPy::setTransformation(), and RobotGui::ViewProviderRobotObject::updateData().
◆ setTransformation() [2/2]
|
virtual |
References pcTransform.
◆ setupContextMenu()
set up the context-menu with the supported edit modes
Reimplemented in PartDesignGui::ViewProvider, PartDesignGui::ViewProviderSubShapeBinder, Gui::ViewProviderPart, PartDesignGui::ViewProviderBody, SpreadsheetGui::ViewProviderSheet, SketcherGui::ViewProviderSketch, PartDesignGui::ViewProviderPrimitive, FemGui::ViewProviderFemMeshShapeNetgen, PartGui::ViewProviderSpline, PartDesignGui::ViewProviderHole, RaytracingGui::ViewProviderLux, PartDesignGui::ViewProviderBase, RaytracingGui::ViewProviderPovray, RobotGui::ViewProviderTrajectory, Gui::ViewProviderTextDocument, Gui::ViewProviderLink, PartGui::ViewProviderPartExt, PartDesignGui::ViewProviderBoolean, PartDesignGui::ViewProviderShapeBinder, TechDrawGui::ViewProviderPage, PartDesignGui::ViewProviderTransformed, Gui::ViewProviderDragger, PartDesignGui::ViewProviderDatum, PartGui::ViewProviderThickness, PartGui::ViewProviderOffset, MeshGui::ViewProviderMesh, Gui::ViewProviderAnnotationLabel, PartGui::ViewProviderChamfer, TechDrawGui::ViewProviderProjGroup, FemGui::ViewProviderFemAnalysis, TechDrawGui::ViewProviderProjGroupItem, PartGui::ViewProviderFillet, PartDesignGui::ViewProviderLoft, PartDesignGui::ViewProviderPipe, PartDesignGui::ViewProviderGroove, PartDesignGui::ViewProviderPocket, PartDesignGui::ViewProviderRevolution, PartGui::ViewProviderMirror, PartDesignGui::ViewProviderPad, PartDesignGui::ViewProviderDressUp, FemGui::ViewProviderFemConstraint, DrawingGui::ViewProviderDrawingPage, SurfaceGui::ViewProviderFilling, and SurfaceGui::ViewProviderGeomFillSurface.
Referenced by Gui::TreeWidget::contextMenuEvent(), Gui::ViewProviderTextDocument::setupContextMenu(), TechDrawGui::ViewProviderPage::setupContextMenu(), and Gui::ViewProviderLink::setupContextMenu().
◆ setUpdatesEnabled()
void ViewProvider::setUpdatesEnabled | ( | bool | enable | ) |
References setStatus(), and Gui::UpdateData.
◆ setVisible()
void ViewProvider::setVisible | ( | bool | s | ) |
References hide(), and show().
Referenced by FemGui::TaskDlgFemConstraintInitialTemperature::open(), FemGui::TaskDlgFemConstraintFixed::open(), FemGui::TaskDlgFemConstraintPlaneRotation::open(), FemGui::TaskDlgFemConstraintPressure::open(), FemGui::TaskDlgFemConstraintContact::open(), FemGui::TaskDlgFemConstraintTemperature::open(), FemGui::TaskDlgFemConstraintHeatflux::open(), FemGui::TaskDlgFemConstraintTransform::open(), FemGui::TaskDlgFemConstraintForce::open(), FemGui::TaskDlgFemConstraint::open(), FemGui::TaskDlgFemConstraintPulley::open(), FemGui::TaskDlgFemConstraintDisplacement::open(), and Gui::ViewProviderOrigin::setTemporaryVisibility().
◆ show()
|
virtual |
Shows the view provider.
Reimplemented in Gui::ViewProviderDocumentObject, TechDrawGui::ViewProviderDrawingView, TechDrawGui::ViewProviderPage, TechDrawGui::ViewProviderTemplate, DrawingGui::ViewProviderDrawingClip, FemGui::ViewProviderFemAnalysis, TechDrawGui::ViewProviderViewClip, FemGui::ViewProviderFemPostObject, DrawingGui::ViewProviderDrawingView, MeshGui::ViewProviderMeshCurvature, InspectionGui::ViewProviderInspection, and DrawingGui::ViewProviderDrawingPage.
Referenced by PartGui::DlgFilletEdges::accept(), PartDesignGui::ViewProvider::makeTemporaryVisible(), PartDesignGui::ViewProvider::onDelete(), PartGui::ViewProviderOffset::onDelete(), PartGui::ViewProviderThickness::onDelete(), PartGui::OffsetWidget::reject(), PartGui::ThicknessWidget::reject(), PartDesignGui::TaskDlgSketchBasedParameters::reject(), PartDesignGui::TaskDlgFeatureParameters::reject(), PartGui::DlgFilletEdges::setupFillet(), setVisible(), Gui::ViewProviderPy::show(), Gui::ViewProviderDocumentObject::show(), Mod.Show.mTempoVis.TempoVis::show_all_dependencies(), Mod.Show.mTempoVis.TempoVis::show_all_dependent(), Gui::Application::showViewProvider(), update(), and Gui::ViewProviderDocumentObject::updateView().
◆ showInTree()
|
virtual |
Tell the tree view if this object should appear there.
Reimplemented in Gui::ViewProviderDocumentObject.
◆ startEditing()
|
virtual |
Reimplemented in PartDesignGui::ViewProviderTransformed, Gui::ViewProviderDragger, and Gui::ViewProviderLink.
References setEdit().
Referenced by draftguitools.gui_edit.Edit::evaluate_menu_action(), draftguitools.gui_edit.Edit::mousePressed(), Gui::ViewProviderDragger::startEditing(), PartDesignGui::ViewProviderTransformed::startEditing(), and Gui::ViewProviderLink::startEditing().
◆ testStatus()
bool Gui::ViewProvider::testStatus | ( | ViewStatus | pos | ) | const |
◆ toString()
std::string ViewProvider::toString | ( | ) | const |
References pcRoot, and Gui::SoFCDB::writeNodesToString().
Referenced by Gui::ViewProviderPy::toString().
◆ unsetEdit()
|
protectedvirtual |
is called when you lose the edit mode
Reimplemented in Gui::ViewProviderOriginFeature, PartGui::ViewProviderPartExt, PartDesignGui::ViewProviderDatum, PartDesignGui::ViewProvider, PartDesignGui::ViewProviderShapeBinder, TechDrawGui::ViewProviderPage, PartDesignGui::ViewProviderTransformed, TechDrawGui::ViewProviderDrawingView, Gui::ViewProviderDragger, TechDrawGui::ViewProviderGeomHatch, TechDrawGui::ViewProviderHatch, SketcherGui::ViewProviderSketch, PartGui::ViewProviderThickness, PartGui::ViewProviderOffset, MeshGui::ViewProviderMesh, FemGui::ViewProviderFemAnalysis, FemGui::ViewProviderFemPostFunction, PartGui::ViewProviderChamfer, Gui::ViewProviderAnnotationLabel, TechDrawGui::ViewProviderViewPart, TechDrawGui::ViewProviderBalloon, TechDrawGui::ViewProviderViewSection, TechDrawGui::ViewProviderProjGroup, TechDrawGui::ViewProviderWeld, TechDrawGui::ViewProviderProjGroupItem, PartGui::ViewProviderFillet, FemGui::ViewProviderFemPostObject, PartDesignGui::ViewProviderPipe, PointsGui::ViewProviderPoints, PartDesignGui::ViewProviderLoft, PartDesignGui::ViewProviderPrimitive, PartGui::ViewProviderMirror, PathGui::ViewProviderPathCompound, RaytracingGui::ViewProviderLux, PartDesignGui::ViewProviderBase, RaytracingGui::ViewProviderPovray, RobotGui::ViewProviderTrajectoryDressUp, RobotGui::ViewProviderTrajectoryCompound, FemGui::ViewProviderSetElements, FemGui::ViewProviderSetFaces, FemGui::ViewProviderSetGeometry, FemGui::ViewProviderSetNodes, RobotGui::ViewProviderEdge2TracObject, FemGui::ViewProviderFemConstraint, PartGui::ViewProvider2DObject, PartGui::ViewProviderCurveNet, TechDrawGui::ViewProviderLeader, TechDrawGui::ViewProviderRichAnno, SurfaceGui::ViewProviderFilling, PartGui::ViewProviderImport, and SurfaceGui::ViewProviderGeomFillSurface.
Referenced by finishEditing(), PathScripts.PathJobGui.ViewProvider::uneditObject(), TechDrawGui::ViewProviderDrawingView::unsetEdit(), and FemGui::ViewProviderFemAnalysis::unsetEdit().
◆ unsetEditViewer()
|
virtual |
restores viewer settings when leaving editing mode
Reimplemented in Gui::ViewProviderLink, Gui::ViewProviderDragger, and SketcherGui::ViewProviderSketch.
Referenced by Gui::View3DInventorViewer::resetEditingViewProvider().
◆ update()
|
virtual |
update the content of the ViewProvider this method have to implement the recalculation of the ViewProvider.
There are different reasons to update. E.g. only the view attribute has changed, or the data has manipulated.
Reimplemented in Gui::ViewProviderDocumentObject.
References hide(), isShow(), isUpdatesEnabled(), show(), and updateData().
Referenced by ArchAxis.AxisSystemTaskPanel::addElement(), ArchSectionPlane.SectionPlaneTaskPanel::addElement(), ArchComponent.ComponentTaskPanel::addElement(), DraftGui.FacebinderTaskPanel::addElement(), femtaskpanels.task_result_mechanical._TaskPanel::calculate(), Spreadsheet_legacy.SpreadsheetView::changeCell(), draftguitools.gui_edit.Edit::endEditing(), draftguitools.gui_trackers.boxTracker::height(), ArchAxis.CommandArchGrid::IsActive(), draftguitools.gui_trackers.rectangleTracker::p3(), Plot.Plot::plot(), Spreadsheet_legacy.SpreadsheetView::recompute(), ArchAxis.AxisSystemTaskPanel::removeElement(), ArchSectionPlane.SectionPlaneTaskPanel::removeElement(), ArchComponent.ComponentTaskPanel::removeElement(), DraftGui.FacebinderTaskPanel::removeElement(), draftguitools.gui_trackers.gridTracker::reset(), ArchNesting.Nester::run(), Gui::Document::slotChangedObject(), Gui::ViewProviderDocumentObject::update(), and draftguitools.gui_edit.Edit::update_object().
◆ updateData()
|
virtual |
Reimplemented in TechDrawGui::ViewProviderPage, SpreadsheetGui::ViewProviderSheet, PartDesignGui::ViewProviderBody, TechDrawGui::ViewProviderViewClip, PartGui::ViewProviderSpline, FemGui::ViewProviderFemPostPipeline, FemGui::ViewProviderFemConstraint, Gui::ViewProviderLink, PartGui::ViewProviderPartExt, PartDesignGui::ViewProvider, TechDrawGui::ViewProviderDrawingView, Gui::ViewProviderDragger, TechDrawGui::ViewProviderHatch, TechDrawGui::ViewProviderGeomHatch, Gui::ViewProviderPlacement, TechDrawGui::ViewProviderTemplate, MeshGui::ViewProviderMeshObject, MeshGui::ViewProviderIndexedFaceSet, FemGui::ViewProviderFemPostSphereFunction, SketcherGui::ViewProviderSketch, FemGui::ViewProviderFemPostPlaneFunction, PointsGui::ViewProviderStructured, PointsGui::ViewProviderScattered, MeshGui::ViewProviderMesh, TechDrawGui::ViewProviderViewPart, PartGui::ViewProviderChamfer, TechDrawGui::ViewProviderDimension, PartGui::ViewProviderMultiCommon, Gui::ViewProviderAnnotationLabel, DrawingGui::ViewProviderDrawingClip, TechDrawGui::ViewProviderBalloon, TechDrawGui::ViewProviderViewSection, TechDrawGui::ViewProviderProjGroup, TechDrawGui::ViewProviderWeld, TechDrawGui::ViewProviderAnnotation, TechDrawGui::ViewProviderSymbol, PartGui::ViewProviderCompound, PartGui::ViewProviderFillet, Gui::ViewProviderMeasureDistance, TechDrawGui::ViewProviderProjGroupItem, TechDrawGui::ViewProviderSpreadsheet, FemGui::ViewProviderFemPostFunctionProvider, MeshPartGui::ViewProviderCrossSections, TechDrawGui::ViewProviderImage, DrawingGui::ViewProviderDrawingView, PartGui::ViewProviderCrossSections, TechDrawGui::ViewProviderTile, FemGui::ViewProviderFemConstraintTransform, FemGui::ViewProviderFemPostObject, Gui::ViewProviderInventorObject, PartGui::ViewProviderRuledSurface, FemGui::ViewProviderFemConstraintContact, FemGui::ViewProviderFemConstraintDisplacement, FemGui::ViewProviderFemConstraintHeatflux, FemGui::ViewProviderFemConstraintInitialTemperature, FemGui::ViewProviderFemConstraintPlaneRotation, FemGui::ViewProviderFemConstraintTemperature, PathGui::ViewProviderAreaView, PartGui::ViewProviderBoolean, PartDesignGui::ViewProviderDatumPlane, FemGui::ViewProviderFemConstraintBearing, FemGui::ViewProviderFemConstraintFixed, FemGui::ViewProviderFemConstraintFluidBoundary, FemGui::ViewProviderFemConstraintForce, FemGui::ViewProviderFemConstraintGear, FemGui::ViewProviderFemConstraintPulley, FemGui::ViewProviderFemMeshShapeNetgen, PartDesignGui::ViewProviderPrimitive, FemGui::ViewProviderFemMesh, PartGui::ViewProviderMultiFuse, PartDesignGui::ViewProviderAddSub, PathGui::ViewProviderArea, MeshGui::ViewProviderMeshCurvature, PartGui::ViewProviderCustom, SketcherGui::ViewProviderCustom, FemGui::ViewProviderFemConstraintPressure, PartGui::ViewProviderPartReference, PathGui::ViewProviderPathShape, MeshGui::ViewProviderMeshFaceSet, PathGui::ViewProviderPath, MeshGui::ViewProviderMeshTransform, Gui::ViewProviderGeometryObject, DrawingGui::ViewProviderDrawingPage, InspectionGui::ViewProviderInspection, Gui::ViewProviderAnnotation, PartGui::ViewProvider2DObject, PartGui::ViewProviderCurveNet, MeshGui::ViewProviderMeshNode, TechDrawGui::ViewProviderLeader, TechDrawGui::ViewProviderRichAnno, RobotGui::ViewProviderRobotObject, Gui::ViewProviderExtern, Gui::ViewProviderOriginFeature, RobotGui::ViewProviderTrajectory, PartDesignGui::ViewProviderDatumCoordinateSystem, ImageGui::ViewProviderImagePlane, Gui::ViewProviderVRMLObject, and PartDesignGui::ViewProviderDatumLine.
Referenced by PathScripts.PathJobDlg.JobCreate::exec_(), Gui::FreeCADGui_subgraphFromObject(), draftviewproviders.view_wire.ViewProviderWire::onChanged(), draftviewproviders.view_dimension.ViewProviderLinearDimension::onChanged(), draftviewproviders.view_dimension.ViewProviderAngularDimension::onChanged(), PathScripts.PathOpGui.TaskPanelPage::pageUpdateData(), PathScripts.PathSetupSheetGui.OpTaskPanel::setupUi(), update(), TechDrawGui::ViewProviderTemplate::updateData(), TechDrawGui::ViewProviderGeomHatch::updateData(), TechDrawGui::ViewProviderHatch::updateData(), Gui::ViewProviderDragger::updateData(), Gui::ViewProviderAnnotation::updateData(), DrawingGui::ViewProviderDrawingPage::updateData(), TechDrawGui::ViewProviderDrawingView::updateData(), TechDrawGui::ViewProviderPage::updateData(), FemGui::ViewProviderFemPostFunctionProvider::updateData(), TechDrawGui::ViewProviderProjGroupItem::updateData(), Gui::ViewProviderMeasureDistance::updateData(), Gui::ViewProviderAnnotationLabel::updateData(), FemGui::ViewProviderFemPostPlaneFunction::updateData(), Gui::ViewProviderLink::updateData(), FemGui::ViewProviderFemPostSphereFunction::updateData(), and Gui::ViewProviderDocumentObject::updateView().
◆ useNewSelectionModel()
|
virtual |
indicates if the ViewProvider use the new Selection model
Reimplemented in Gui::ViewProviderLink, PartGui::ViewProviderPartExt, TechDrawGui::ViewProviderGeomHatch, Gui::ViewProviderPlacement, PartDesignGui::ViewProviderDatum, TechDrawGui::ViewProviderDrawingView, TechDrawGui::ViewProviderPage, SpreadsheetGui::ViewProviderSheet, TechDrawGui::ViewProviderHatch, TechDrawGui::ViewProviderTemplate, MeshGui::ViewProviderMesh, TechDrawGui::ViewProviderDimension, TechDrawGui::ViewProviderViewPart, DrawingGui::ViewProviderDrawingClip, TechDrawGui::ViewProviderBalloon, TechDrawGui::ViewProviderWeld, Gui::ViewProviderMeasureDistance, FemGui::ViewProviderFemMesh, TechDrawGui::ViewProviderAnnotation, TechDrawGui::ViewProviderSymbol, TechDrawGui::ViewProviderSpreadsheet, Gui::ViewProviderInventorObject, TechDrawGui::ViewProviderImage, TechDrawGui::ViewProviderViewClip, DrawingGui::ViewProviderDrawingView, TechDrawGui::ViewProviderProjGroup, TechDrawGui::ViewProviderTile, TechDrawGui::ViewProviderProjGroupItem, PathGui::ViewProviderPath, MeshGui::ViewProviderMeshCurvature, TechDrawGui::ViewProviderLeader, DrawingGui::ViewProviderDrawingPage, and TechDrawGui::ViewProviderRichAnno.
References Gui::ViewParams::instance().
Referenced by Gui::SoFCUnifiedSelection::doAction(), Gui::View3DInventorPy::getObjectInfo(), and Gui::View3DInventorPy::getObjectsInfo().
Member Data Documentation
◆ overrideMode
|
protected |
◆ pcAnnotation
|
protected |
The root separator for annotations.
Referenced by getAnnotation(), and ~ViewProvider().
◆ pcModeSwitch
|
protected |
this is the mode switch, all the different viewing modes are collected here
Referenced by addDisplayMaskMode(), Gui::ViewProviderExtern::adjustDocumentName(), PartGui::ViewProviderPartExt::attach(), getBoundingBox(), Gui::ViewProviderPlacement::getDetailPath(), Gui::ViewProviderDocumentObject::getDetailPath(), getDetailPath(), Gui::ViewProviderLink::getDetailPath(), getDisplayMaskMode(), Gui::ViewProviderDocumentObject::getElementPicked(), hide(), isShow(), Gui::ViewProviderLink::onBeforeChange(), Gui::ViewProviderLink::onChanged(), partialRender(), setOverrideMode(), PartDesignGui::ViewProviderAddSub::setPreviewDisplayMode(), and ~ViewProvider().
◆ pcRoot
|
protected |
The root Separator of the ViewProvider.
Referenced by PartGui::ViewProviderPartExt::attach(), getAnnotation(), getBoundingBox(), Gui::ViewProviderPlacement::getDetailPath(), getDetailPath(), Gui::ViewProviderLink::getDetailPath(), PartDesignGui::ViewProviderTransformed::setEdit(), PartGui::ViewProviderMirror::setEdit(), Gui::ViewProviderAnnotationLabel::setEdit(), setRenderCacheMode(), Gui::ViewProviderGeometryObject::setSelectable(), Gui::ViewProviderGeometryObject::showBoundingBox(), PartGui::ViewProviderSpline::showControlPoints(), MeshGui::ViewProviderMeshFaceSet::showOpenEdges(), MeshGui::ViewProviderIndexedFaceSet::showOpenEdges(), MeshGui::ViewProviderMeshObject::showOpenEdges(), toString(), PartDesignGui::ViewProviderTransformed::unsetEdit(), PartGui::ViewProviderMirror::unsetEdit(), Gui::ViewProviderAnnotationLabel::unsetEdit(), PartGui::ViewProviderCrossSections::ViewProviderCrossSections(), MeshPartGui::ViewProviderCrossSections::ViewProviderCrossSections(), and ~ViewProvider().
◆ pcTransform
|
protected |
this is transformation for the provider
Referenced by Gui::ViewProviderDragger::setEdit(), setTransformation(), Gui::ViewProviderDragger::unsetEdit(), Gui::ViewProviderVRMLObject::updateData(), Gui::ViewProviderDragger::updateData(), Gui::ViewProviderInventorObject::updateData(), Gui::ViewProviderLink::updateDataPrivate(), and ~ViewProvider().
◆ pyViewObject
|
protected |
◆ signalChangeIcon
boost::signals2::signal<void ()> Gui::ViewProvider::signalChangeIcon |
◆ signalChangeStatusTip
boost::signals2::signal<void (const QString&)> Gui::ViewProvider::signalChangeStatusTip |
signal on status tip change
Referenced by Gui::DocumentObjectData::DocumentObjectData().
◆ signalChangeToolTip
boost::signals2::signal<void (const QString&)> Gui::ViewProvider::signalChangeToolTip |
signal on tooltip change
Referenced by Gui::DocumentObjectData::DocumentObjectData().
◆ sPixmap
|
protected |
Referenced by Gui::ViewProviderLink::checkIcon(), Gui::ViewProviderDocumentObjectGroup::getIcon(), Gui::ViewProviderLink::getIcon(), getIcon(), TechDrawGui::ViewProviderProjGroupItem::updateData(), PartDesignGui::ViewProviderBoolean::ViewProviderBoolean(), PartDesignGui::ViewProviderDatumCoordinateSystem::ViewProviderDatumCoordinateSystem(), FemGui::ViewProviderFemMesh::ViewProviderFemMesh(), Gui::ViewProviderGeometryObject::ViewProviderGeometryObject(), Gui::ViewProviderLink::ViewProviderLink(), PartGui::ViewProviderPartExt::ViewProviderPartExt(), and Gui::ViewProviderTextDocument::ViewProviderTextDocument().
◆ StatusBits
|
protected |
The documentation for this class was generated from the following files:
- src/Gui/ViewProvider.h
- src/Gui/ViewProvider.cpp