From 7d512fd8cec09b50909296c627a0b9ab4d59cca9 Mon Sep 17 00:00:00 2001 From: Ingo Paschke Date: Thu, 21 May 2026 11:31:24 +0200 Subject: [PATCH] shk: show item glyphs in the pay-bill menu menu_pick_pay_items() passed &nul_glyphinfo to add_menu so port windowports never had a tile/glyph to render alongside each entry on the bill. Compute the proper glyph_info from the bill's obj, matching the pattern src/invent.c already uses for inventory menus. --- src/shk.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/shk.c b/src/shk.c index bd87b8849..cb86dfaa5 100644 --- a/src/shk.c +++ b/src/shk.c @@ -1675,7 +1675,8 @@ menu_pick_pay_items( menu_item *pick_list = (menu_item *) 0; char *p, buf[BUFSZ]; long amt, largest_amt, save_quan; - int i, j, n, amt_width; + int i, j, n, amt_width, tmpglyph; + glyph_info tmpglyphinfo; any = cg.zeroany; win = create_nhwindow(NHW_MENU); @@ -1716,7 +1717,9 @@ menu_pick_pay_items( isn't hallucinating; also, that would mess up the alignment */ Snprintf(buf, sizeof buf, "%*ld Zm, %s", amt_width, amt, p); any.a_int = i + 1; /* +1: avoid 0 */ - add_menu(win, &nul_glyphinfo, &any, 0, 0, ATR_NONE, NO_COLOR, buf, + tmpglyph = obj_to_glyph(otmp, rn2_on_display_rng); + map_glyphinfo(0, 0, tmpglyph, 0U, &tmpglyphinfo); + add_menu(win, &tmpglyphinfo, &any, 0, 0, ATR_NONE, NO_COLOR, buf, MENU_ITEMFLAGS_NONE); }