That is one way... create your own custom widget and override the contextmenu event. From designer, you can promote the widget to your custom widget.
The other way is -
Set QWidget::setContextMenuPolicy to Qt::CustomContextMenu, and connect QWidget::customContextMenuRequested() signal to your handling class. and show the menu as you want in the global pos.
Bookmarks