]> granicus.if.org Git - nethack/commitdiff
from <Someone>
authornethack.allison <nethack.allison>
Thu, 14 Feb 2002 00:55:17 +0000 (00:55 +0000)
committernethack.allison <nethack.allison>
Thu, 14 Feb 2002 00:55:17 +0000 (00:55 +0000)
( #enhance screen is still broken though). I attached a small
patch with minor adjustments.

src/spell.c
win/win32/mhmenu.c

index 03fb748631b76e361203011d5c682378accb5a93..68967ff62a3f85386eeefb5cb8bb253fd06aa391 100644 (file)
@@ -1001,11 +1001,11 @@ int *spell_no;
        if (!iflags.menu_tab_sep)
                Sprintf(buf, "%-20s     Level  %-12s Fail", "    Name", "Category");
        else
-               Sprintf(buf, "%-20s\tLevel\tCategory\tFail", "Name");
+               Sprintf(buf, "Name\tLevel\tCategory\tFail");
        add_menu(tmpwin, NO_GLYPH, &any, 0, 0, ATR_NONE, buf, MENU_UNSELECTED);
        for (i = 0; i < MAXSPELL && spellid(i) != NO_SPELL; i++) {
                Sprintf(buf, iflags.menu_tab_sep ?
-                       "%s\t%2d%s\t%s\t%3d%%" : "%-20s  %2d%s   %-12s %3d%%",
+                       "%s\t%-d%s\t%s\t%-d%%" : "%-20s  %2d%s   %-12s %3d%%",
                        spellname(i), spellev(i),
                        spellknow(i) ? " " : "*",
                        spelltypemnemonic(spell_skilltype(spellid(i))),
index 4dafda448ed22690cf3d3719f74c0dafa40210fc..ac942dd375e8a7809c134ac798715d040895c4d5 100644 (file)
@@ -485,7 +485,7 @@ void onMSNHCommand(HWND hWnd, WPARAM wParam, LPARAM lParam)
                p = strchr(data->menu.items[new_item].str, '\t');
                while( p ) {
                        data->menu.tab_stop_size = 
-                               max( data->menu.tab_stop_size, p - p1 );
+                               max( data->menu.tab_stop_size, p - p1 + 1 );
                        p1 = p;
                        p = strchr(p+1, '\t');
                }