Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
6.5.0
-
None
-
-
e9a1c5321 (dev), eb5f18375 (6.6)
Description
Native feeling macOS QMessageBox does not support title and changing button texts using msgbox->button(id)->setText(text).
Resulting message box contains always default English button texts, even on non-English macOS (I have correct .lproj subfolders, so for example native Open/Save file dialogs in Qt have localised buttons). BTW, messagebox title and icon are not shown either.
Suggestion: in case it is not possible to change the button texts in native QMessageBox on macOS, please use the old-style QMessageBox style.
QMessageBox aMsgBox(QMessageBox::Information, "Title", "Some message", QMessageBox::Yes | QMessageBox::No | QMessageBox::Cancel, this);
aMsgBox.button(QMessageBox::Yes)->setText("Positive");
aMsgBox.button(QMessageBox::No)->setText("Negative");
aMsgBox.exec();