From: PatR Date: Tue, 24 Nov 2020 01:39:00 +0000 (-0800) Subject: Qt font selection dropdown menu X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=0c56c063163f410391dd771bff38e09dbf917a89;p=nethack Qt font selection dropdown menu In "Qt settings" (or "Preferences" for OSX), the current font size would show "Medium" if that was the current setting. So far, so good. However, if you clicked on the up/down arrows to get the dropdown menu, it was truncated to "Mediu" there regardless of current setting. Force the menu to be wide enough to show "Medium". --- diff --git a/win/Qt/qt_set.cpp b/win/Qt/qt_set.cpp index 939ae89a7..e3e0295b5 100644 --- a/win/Qt/qt_set.cpp +++ b/win/Qt/qt_set.cpp @@ -141,6 +141,7 @@ NetHackQtSettings::NetHackQtSettings() : connect(&dollheight, SIGNAL(valueChanged(int)), this, SLOT(resizeDoll())); #endif + fontsize.setMinimumContentsLength((int) strlen("Medium")); fontsize.addItem("Huge"); fontsize.addItem("Large"); fontsize.addItem("Medium");