diff --git a/src/gui/PasswordComboBox.cpp b/src/gui/PasswordComboBox.cpp index af8e9949d..f11311a9a 100644 --- a/src/gui/PasswordComboBox.cpp +++ b/src/gui/PasswordComboBox.cpp @@ -45,7 +45,13 @@ void PasswordComboBox::setEcho(bool echo) // add fake item to show visual indication that a popup is available addItem(""); - setStyleSheet("QComboBox { font-family: monospace; }"); +#ifdef Q_OS_MAC + // Qt on Mac OS doesn't seem to know the generic monospace family (tested with 4.8.6) + setStyleSheet("QComboBox { font-family: monospace,Menlo,Monaco; }"); +#else + setStyleSheet("QComboBox { font-family: monospace,Courier; }"); +#endif + } else { // clear items so the combobox indicates that no popup menu is available diff --git a/src/gui/PasswordEdit.cpp b/src/gui/PasswordEdit.cpp index 853269614..b68eef68b 100644 --- a/src/gui/PasswordEdit.cpp +++ b/src/gui/PasswordEdit.cpp @@ -56,7 +56,12 @@ void PasswordEdit::updateStylesheet() QString stylesheet("QLineEdit { "); if (echoMode() == QLineEdit::Normal) { +#ifdef Q_OS_MAC + // Qt on Mac OS doesn't seem to know the generic monospace family (tested with 4.8.6) + stylesheet.append("font-family: monospace,Menlo,Monaco; "); +#else stylesheet.append("font-family: monospace; "); +#endif } if (m_basePasswordEdit && !passwordsEqual()) {