This interface creates ParaView's default context menu in render views.
More...
#include <pqDefaultContextMenu.h>
This interface creates ParaView's default context menu in render views.
It has priority 0, so you can modify the QMenu it creates by using a lower (negative) priority in your own custom interface. You can eliminate the default menu by assigning your custom interface a positive priority and have its contextMenu() method return true.
- See also
- pqPipelineContextMenuBehavior
Definition at line 30 of file pqDefaultContextMenu.h.
◆ pqDefaultContextMenu()
pqDefaultContextMenu::pqDefaultContextMenu |
( |
QObject * |
parent = nullptr | ) |
|
◆ ~pqDefaultContextMenu()
pqDefaultContextMenu::~pqDefaultContextMenu |
( |
| ) |
|
|
override |
◆ contextMenu()
bool pqDefaultContextMenu::contextMenu |
( |
QMenu * |
menu, |
|
|
pqView * |
viewContext, |
|
|
const QPoint & |
viewPoint, |
|
|
pqRepresentation * |
dataContext, |
|
|
const QList< unsigned int > & |
dataBlockContext |
|
) |
| const |
|
overridevirtual |
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.
Reimplemented from pqContextMenuInterface.
◆ priority()
int pqDefaultContextMenu::priority |
( |
| ) |
const |
|
inlineoverridevirtual |
◆ hide
void pqDefaultContextMenu::hide |
( |
| ) |
|
|
protectedslot |
called to hide the representation.
◆ reprTypeChanged
void pqDefaultContextMenu::reprTypeChanged |
( |
QAction * |
action | ) |
|
|
protectedslot |
called to change the representation type.
◆ colorMenuTriggered
void pqDefaultContextMenu::colorMenuTriggered |
( |
QAction * |
action | ) |
|
|
protectedslot |
called to change the coloring mode.
◆ showAllBlocks
void pqDefaultContextMenu::showAllBlocks |
( |
| ) |
const |
|
protectedslot |
called to show all blocks.
◆ buildColorFieldsMenu()
called to build the color arrays submenu.
◆ Position
QPoint pqDefaultContextMenu::Position |
|
mutableprotected |
◆ PickedRepresentation
The documentation for this class was generated from the following file: