When QToolBar
and QDockWidget
widgets are used, they automatically generate a context menu which allows you to show/hide these dock and toolbar widgets (see the screenshot).
How can I get these context menu actions?
Usage example: E.g., I want to add the same actions (to show/hide docks and toolbars), to the "Window" QMenu
in the menu bar without manually repeating the previously mentioned context menu.