[Paraview-developers] Changing context menu of a view from a plugin

Utkarsh Ayachit utkarsh.ayachit at kitware.com
Fri Apr 22 07:27:46 EDT 2011


Jerome,

To get rid of the existing behavior, you can do something like:

delete mainWindow->findChild<pqPipelineContextMenuBehavior*>()

> I also would like the buildMenu function to be called everytime, not
> only when a pqDataRepresentation is picked. Should I submit a patch?

That may need some restructuring, since ParaView doesn't want this. We
want the "view-based" context menu when clicking in empty spaces. But
it's doable.

> Subsidiary question: right clicking on an ImageSlice representation
> makes the eventFilter to behave as nothing were found... Is it on
> purpose?

Some representations such as slice/outline cannot be selected yet.
Since the context menu depends on the selection mechanism, it cannot
work unless that feature is implemented. I has been in our todo list
for sometime, but has not been high on the priority queue.

Utkarsh


More information about the Paraview-developers mailing list