Details
-
Bug
-
Resolution: Duplicate
-
P2: Important
-
None
-
5.15.0
-
None
Description
If a multi-monitor setup is used and an Menu of a toolbar action is opened the menu is always displayed on the primary monitor. If the window is on the secondary monitor the menu should be displayed there.
Code for Example:
#include <QAction> #include <QApplication> #include <QMainWindow> #include <QMenu> #include <QToolBar> int main(int argc, char *argv[]) { QApplication a(argc, argv); QMainWindow w; auto menu = new QMenu(); menu->addAction( "Menu Action 1" ); auto action = new QAction(); action->setText( "Test Action" ); action->setMenu( menu ); auto toolbar = new QToolBar(); toolbar->addAction( action ); w.addToolBar( Qt::ToolBarArea::LeftToolBarArea, toolbar ); w.show(); return a.exec(); }
Attachments
Issue Links
- duplicates
-
QTBUG-84462 QToolButton popup menu only shows on primary screen
- Closed