]> granicus.if.org Git - nethack/commitdiff
Qt extended commands
authorPatR <rankin@nethack.org>
Sun, 16 Jan 2022 22:41:17 +0000 (14:41 -0800)
committerPatR <rankin@nethack.org>
Sun, 16 Jan 2022 22:41:17 +0000 (14:41 -0800)
The substantial increase in extended commands has forced the grid of
commands to be expanded, otherwise the bottom of each column ends up
off the bottom of the screen.

The widget supporting the '#' command doesn't include scrollbars.
It really needs to be able to include those when needed but I don't
know how to do that.

win/Qt/qt_xcmd.cpp

index f1c203903fdf7600974a8d17116b7642341030fe..11e8e6fe1d1b92e15e6b6ca4fdc2186fa6439804 100644 (file)
@@ -273,8 +273,8 @@ NetHackQtExtCmdRequestor::NetHackQtExtCmdRequestor(QWidget *parent) :
        as an extended command, that resulted in so many rows that some of
        the grid was chopped off at the bottom of the screen and the buttons
        in that portion were out of reach */
-    unsigned ncols = (set == all_cmds) ? 8
-                     : (set == normal_cmds) ? 7
+    unsigned ncols = (set == all_cmds) ? 9
+                     : (set == normal_cmds) ? 8
                        : (set == autocomplete_cmds) ? (WizardMode ? 6 : 5)
                          : (set == wizard_cmds) ? (byRow ? 6 : 5)
                            : 1; // can't happen