|
ParaView
|
pq3DWidget is the abstract superclass for all 3D widgets. More...
#include <pq3DWidget.h>


Public Slots | |
| void | setWidgetVisible (bool) |
| Sets 3D widget visibility. | |
| void | showWidget () |
| Makes the 3D widget visible. | |
| void | hideWidget () |
| Hides the 3D widget. | |
| virtual void | select () |
| Activates the widget. Respects the visibility flag. | |
| virtual void | deselect () |
| Deactivates the widget. | |
| virtual void | accept () |
| Accepts pending changes. | |
| virtual void | reset () |
| Resets pending changes. | |
| virtual void | setView (pqView *) |
| Set the view that this panel works with. | |
| virtual void | resetBounds () |
| Resets the bounds of the 3D widget to the reference proxy bounds. | |
| virtual void | setUseSelectionDataBounds (bool use) |
| When set to true, instead of using the referenceProxy to obtain the default bounds to reset to, it will use the bounds for the selected sources as indicated by pqApplicationCore::getSelectionModel()->getSelectionDataBounds(). | |
| bool | useSelectionDataBounds () |
Signals | |
| void | widgetVisibilityChanged (bool) |
| Notifies observers that widget visibility has changed. | |
| void | widgetStartInteraction () |
| Notifies observers that the user is dragging the 3D widget. | |
| void | widgetEndInteraction () |
| Notifies observers that the user is done dragging the 3D widget. | |
| void | widgetInteraction () |
| Notifies observers that the user is dragging the 3D widget. | |
Public Member Functions | |
| pq3DWidget (vtkSMProxy *referenceProxy, vtkSMProxy *proxy, QWidget *parent=0) | |
| virtual | ~pq3DWidget () |
| vtkSMProxy * | getControlledProxy () const |
| Controlled proxy is a proxy which is controlled by the 3D widget. | |
| vtkSMProxy * | getReferenceProxy () const |
| void | setHints (vtkPVXMLElement *element) |
| Set the hints XML to be using to map the 3D widget to the controlled proxy. | |
| vtkPVXMLElement * | getHints () const |
| vtkSMNewWidgetRepresentationProxy * | getWidgetProxy () const |
| Return the 3D Widget proxy. | |
| bool | widgetVisible () const |
| Returns true if 3D widget visibility is enabled. | |
| bool | widgetSelected () const |
| Returns true if 3D widget is selected. | |
| pqRenderViewBase * | renderView () const |
| Returns the current render view. | |
| virtual void | resetBounds (double bounds[6])=0 |
| Reset the bounds to the specified bounds. | |
Static Public Member Functions | |
| static QList< pq3DWidget * > | createWidgets (vtkSMProxy *refProxy, vtkSMProxy *proxy) |
Protected Slots | |
| void | render () |
| Called to request a render. | |
| virtual void | pick (double, double, double) |
| Called on each pick, default implementation does nothing. | |
| virtual void | updateMasterEnableState (bool) |
| Called when master/slave change. | |
| void | handleSourceNotification (pqPipelineSource *, char *) |
| Handle custom user notification to show/hide corresponding widget. | |
Protected Member Functions | |
| virtual void | setControlledProperty (const char *function, vtkSMProperty *controlled_property) |
| Subclasses can override this method to map properties to GUI. | |
| void | pickingSupported (const QKeySequence &key) |
| Subclasses should call this method if they support picking. | |
| void | setControlledProperty (vtkSMProperty *widget_property, vtkSMProperty *controlled_property) |
| void | setWidgetProxy (vtkSMNewWidgetRepresentationProxy *) |
| virtual void | onControlledPropertyChanged () |
| Called when one of the controlled properties change (e.g: by undo/redo) | |
| int | getReferenceInputBounds (double bounds[6]) const |
| Used to get the input bounds on for the reference proxy, if any. | |
| virtual void | updateWidgetVisibility () |
| Update the widget visibility according to the WidgetVisible and Selected flags. | |
| virtual void | updateWidgetState (bool visible, bool enable) |
| Update the widget visibility and enable state. | |
| virtual void | updatePickShortcut () |
| updates the enable state of the picking shortcut. | |
| virtual void | updatePickShortcut (bool pickable) |
pq3DWidget is the abstract superclass for all 3D widgets.
This class represents a 3D Widget proxy as well as the GUI for the widget.
Definition at line 50 of file pq3DWidget.h.
| pq3DWidget::pq3DWidget | ( | vtkSMProxy * | referenceProxy, |
| vtkSMProxy * | proxy, | ||
| QWidget * | parent = 0 |
||
| ) |
| virtual pq3DWidget::~pq3DWidget | ( | ) | [virtual] |
| static QList<pq3DWidget*> pq3DWidget::createWidgets | ( | vtkSMProxy * | refProxy, |
| vtkSMProxy * | proxy | ||
| ) | [static] |
| vtkSMProxy* pq3DWidget::getControlledProxy | ( | ) | const |
Controlled proxy is a proxy which is controlled by the 3D widget.
A controlled proxy must provide "Hints" describing how the properties of the controlled proxy are controlled by the 3D widget.
| vtkSMProxy* pq3DWidget::getReferenceProxy | ( | ) | const |
| void pq3DWidget::setHints | ( | vtkPVXMLElement * | element | ) |
Set the hints XML to be using to map the 3D widget to the controlled proxy.
This method must be called only after the controlled proxy has been set. The argument is the element <PropertyGroup> which will be controlled by this widget.
| vtkPVXMLElement* pq3DWidget::getHints | ( | ) | const |
| vtkSMNewWidgetRepresentationProxy* pq3DWidget::getWidgetProxy | ( | ) | const |
Return the 3D Widget proxy.
| bool pq3DWidget::widgetVisible | ( | ) | const |
Returns true if 3D widget visibility is enabled.
Note: this *does not* indicate that the 3D widget is currently visible in the display, since this widget's panel might not be visible.
| bool pq3DWidget::widgetSelected | ( | ) | const |
Returns true if 3D widget is selected.
| pqRenderViewBase* pq3DWidget::renderView | ( | ) | const |
Returns the current render view.
| virtual void pq3DWidget::resetBounds | ( | double | bounds[6] | ) | [pure virtual] |
Reset the bounds to the specified bounds.
This typically calls PlaceWidget on the underlying 3D Widget with reference proxy bounds.
Implemented in pqLineWidget, pqImplicitPlaneWidget, pqPointSourceWidget, pqHandleWidget, pqContourWidget, pqSplineWidget, pqBoxWidget, and pqSphereWidget.
| void pq3DWidget::widgetVisibilityChanged | ( | bool | ) | [signal] |
Notifies observers that widget visibility has changed.
| void pq3DWidget::widgetStartInteraction | ( | ) | [signal] |
Notifies observers that the user is dragging the 3D widget.
| void pq3DWidget::widgetEndInteraction | ( | ) | [signal] |
Notifies observers that the user is done dragging the 3D widget.
| void pq3DWidget::widgetInteraction | ( | ) | [signal] |
Notifies observers that the user is dragging the 3D widget.
| void pq3DWidget::setWidgetVisible | ( | bool | ) | [slot] |
Sets 3D widget visibility.
| void pq3DWidget::showWidget | ( | ) | [slot] |
Makes the 3D widget visible.
| void pq3DWidget::hideWidget | ( | ) | [slot] |
Hides the 3D widget.
| virtual void pq3DWidget::select | ( | ) | [virtual, slot] |
Activates the widget. Respects the visibility flag.
Reimplemented from pqProxyPanel.
Reimplemented in pqImplicitPlaneWidget, pqContourWidget, and pqBoxWidget.
| virtual void pq3DWidget::deselect | ( | ) | [virtual, slot] |
| virtual void pq3DWidget::accept | ( | ) | [virtual, slot] |
Accepts pending changes.
Default implementation pushes the 3D widget information property values to the corresponding properties on the controlled widget. The correspondence is determined from the <Hints> associated with the controlled proxy.
Reimplemented from pqProxyPanel.
Reimplemented in pqImplicitPlaneWidget, pqBoxWidget, and pqSphereWidget.
| virtual void pq3DWidget::reset | ( | ) | [virtual, slot] |
Resets pending changes.
Default implementation pushes the property values of the controlled widget to the 3D widget properties. The correspondence is determined from the <Hints> associated with the controlled proxy.
Reimplemented from pqProxyPanel.
Reimplemented in pqContourWidget, pqImplicitPlaneWidget, pqBoxWidget, and pqSphereWidget.
| virtual void pq3DWidget::setView | ( | pqView * | ) | [virtual, slot] |
Set the view that this panel works with.
Reimplemented from pqProxyPanel.
| virtual void pq3DWidget::resetBounds | ( | ) | [virtual, slot] |
Resets the bounds of the 3D widget to the reference proxy bounds.
This typically calls PlaceWidget on the underlying 3D Widget with reference proxy bounds. This should be explicitly called after the panel is created and the widget is initialized i.e. the reference proxy, controlled proxy and hints have been set. Default implementation uses the getReferenceInputBounds() to get the bounds and then calls resetBounds(double bounds[]). Subclasses generally need to override this resetBounds(double*) method.
Reimplemented in pqPointSourceWidget, pqLineWidget, pqImplicitPlaneWidget, pqContourWidget, pqHandleWidget, pqSplineWidget, pqBoxWidget, and pqSphereWidget.
| virtual void pq3DWidget::setUseSelectionDataBounds | ( | bool | use | ) | [inline, virtual, slot] |
When set to true, instead of using the referenceProxy to obtain the default bounds to reset to, it will use the bounds for the selected sources as indicated by pqApplicationCore::getSelectionModel()->getSelectionDataBounds().
Default is false.
Definition at line 160 of file pq3DWidget.h.
| bool pq3DWidget::useSelectionDataBounds | ( | ) | [inline, slot] |
Definition at line 162 of file pq3DWidget.h.
| void pq3DWidget::render | ( | ) | [protected, slot] |
Called to request a render.
Called on each pick, default implementation does nothing.
Reimplemented in pqLineWidget, and pqHandleWidget.
Definition at line 170 of file pq3DWidget.h.
| virtual void pq3DWidget::updateMasterEnableState | ( | bool | ) | [protected, virtual, slot] |
Called when master/slave change.
| void pq3DWidget::handleSourceNotification | ( | pqPipelineSource * | , |
| char * | |||
| ) | [protected, slot] |
Handle custom user notification to show/hide corresponding widget.
| virtual void pq3DWidget::setControlledProperty | ( | const char * | function, |
| vtkSMProperty * | controlled_property | ||
| ) | [protected, virtual] |
Subclasses can override this method to map properties to GUI.
Default implementation updates the internal datastructures so that default implementations can be provided for accept/reset.
Reimplemented in pqImplicitPlaneWidget, pqLineWidget, pqPointSourceWidget, and pqLineSourceWidget.
| void pq3DWidget::pickingSupported | ( | const QKeySequence & | key | ) | [protected] |
Subclasses should call this method if they support picking.
When the user picks a position, the virtual method pick(double, double, double) will be called.
| void pq3DWidget::setControlledProperty | ( | vtkSMProperty * | widget_property, |
| vtkSMProperty * | controlled_property | ||
| ) | [protected] |
| void pq3DWidget::setWidgetProxy | ( | vtkSMNewWidgetRepresentationProxy * | ) | [protected] |
| virtual void pq3DWidget::onControlledPropertyChanged | ( | ) | [protected, virtual] |
Called when one of the controlled properties change (e.g: by undo/redo)
Used to get the input bounds on for the reference proxy, if any.
returns 1 on success, 0 otherwise.
| virtual void pq3DWidget::updateWidgetVisibility | ( | ) | [protected, virtual] |
Update the widget visibility according to the WidgetVisible and Selected flags.
Reimplemented in pqContourWidget.
| virtual void pq3DWidget::updateWidgetState | ( | bool | visible, |
| bool | enable | ||
| ) | [protected, virtual] |
Update the widget visibility and enable state.
| virtual void pq3DWidget::updatePickShortcut | ( | ) | [protected, virtual] |
updates the enable state of the picking shortcut.
| virtual void pq3DWidget::updatePickShortcut | ( | bool | pickable | ) | [protected, virtual] |
1.7.5.1