Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-112525

macOS 6.5.0 native looking QMessageBox missing title and cannot change button texts

    XMLWordPrintable

Details

    • macOS
    • 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();

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            vestbo Tor Arne Vestbø
            jadamec Jan Adamec
            Votes:
            3 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes