add context menu items to control block appearance properties. More...
#include <pqBlockContextMenu.h>


Public Member Functions | |
| pqBlockContextMenu (QObject *parent=nullptr) | |
| ~pqBlockContextMenu () override | |
| bool | contextMenu (QMenu *menu, pqView *viewContext, const QPoint &viewPoint, pqRepresentation *dataContext, const QStringList &dataBlockContext) const override |
| This is a newer variant of the contextMenu where the dataBlockContext is provided as selectors instead of composite ids. More... | |
| int | priority () const override |
| This method's return value is used to set the precedence of the interface. More... | |
| virtual bool | contextMenu (QMenu *menu, pqView *viewContext, const QPoint &viewPoint, pqRepresentation *dataContext, const QList< unsigned int > &dataBlockContext) const |
| This method is called when a context menu is requested, usually by a right click in a pqView instance. More... | |
| virtual bool | contextMenu (QMenu *menu, pqView *viewContext, const QPoint &viewPoint, pqRepresentation *dataContext, const QStringList &dataBlockContext) const |
| This is a newer variant of the contextMenu where the dataBlockContext is provided as selectors instead of composite ids. More... | |
Public Member Functions inherited from pqContextMenuInterface | |
| pqContextMenuInterface () | |
| virtual | ~pqContextMenuInterface () |
| virtual bool | contextMenu (QMenu *menu, pqView *viewContext, const QPoint &viewPoint, pqRepresentation *dataContext, const QList< unsigned int > &dataBlockContext) const |
| This method is called when a context menu is requested, usually by a right click in a pqView instance. More... | |
add context menu items to control block appearance properties.
pqBlockContextMenu is a concrete implementation of the pqContextMenuInterface that add context-menu actions to control display properties for chosen blocks. This is currently only supported for render view.
Definition at line 19 of file pqBlockContextMenu.h.
| pqBlockContextMenu::pqBlockContextMenu | ( | QObject * | parent = nullptr | ) |
|
override |
|
overridevirtual |
This is a newer variant of the contextMenu where the dataBlockContext is provided as selectors instead of composite ids.
Selectors are more reliable especially when dealing with partitioned datasets and their collections in distributed mode and hence should be preferred.
Reimplemented from pqContextMenuInterface.
|
inlineoverridevirtual |
This method's return value is used to set the precedence of the interface.
Interfaces with greater priority are invoked before others and may cause menu-building to terminate early. ParaView's default context-menu interface uses a priority of 0 and returns false.
If you wish to modify the default menu, assign a negative priority to your interface. If you wish to override the default menu, assign a positive priority to your interface and have contextMenu() return true.
Reimplemented from pqContextMenuInterface.
Definition at line 35 of file pqBlockContextMenu.h.
| virtual bool pqContextMenuInterface::contextMenu |
This method is called when a context menu is requested, usually by a right click in a pqView instance.
This method should return true if (a) the context is one handled by this instance (and presumably it will modify the provided QMenu); and (b) this instance should be the last interface to contribute to the menu. Returning false indicates the context is not one this instance handles or that interfaces with a lower priority may modify the menu.
Each registered interface is called in order of descending priority until one returns true, so your implementation should return false as quickly as possible.
If dataContext is a pqDataRepresentation and holds multiblock data, the dataBlockContext is a list of block IDs to which the menu actions should apply.
| virtual bool pqContextMenuInterface::contextMenu |
This is a newer variant of the contextMenu where the dataBlockContext is provided as selectors instead of composite ids.
Selectors are more reliable especially when dealing with partitioned datasets and their collections in distributed mode and hence should be preferred.
1.8.17 on Wed Mar 27 2024