Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
QMessageBox does not open centered on Mac OS X (Qt 4.8.5)
laseranichris last edited by
this is only a minor issue:
When you open a QMessageBox, it is not centered relative to the parent on Mac OS X.
On Windows it is centered.
Here is the code I used:
box.setText("This is a message box!");
And there is another small issue:
The text displayed within the message box is bold. Even if it is not supposed to be.
This is also different on Windows.
Does anybody have a workaround for this?
jensen82 last edited by
I would fetch the parent window-position and calculate the center-position and set it via move ("Move...":http://qt-project.org/doc/qt-4.8/qwidget.html#pos-prop). You can calc the position by subtracting your widgets geometry.