Added gtkutil helpers to create stock-based images and buttons while keeping GTK3 icon-name mapping centralized in gtkutil.c.

Exposed the new gtkutil stock helper APIs in the header for reuse.
Swapped setup dialog stock button creation to the new gtkutil_button_new_from_stock helper (including the sound play button fallback).
This commit is contained in:
2026-01-30 07:53:50 -07:00
parent 004786655c
commit 537167cd61
3 changed files with 39 additions and 6 deletions

View File

@@ -31,6 +31,8 @@ void gtkutil_destroy (GtkWidget * igad, GtkWidget * dgad);
void gtkutil_destroy_on_esc (GtkWidget *win);
GtkWidget *gtkutil_button (GtkWidget *box, char *stock, char *tip, void *callback,
void *userdata, char *labeltext);
GtkWidget *gtkutil_image_new_from_stock (const char *stock, GtkIconSize size);
GtkWidget *gtkutil_button_new_from_stock (const char *stock, const char *label);
#if HAVE_GTK3
const char *gtkutil_icon_name_from_stock (const char *stock_name);
#endif