aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/jalv_gtk.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/jalv_gtk.c b/src/jalv_gtk.c
index fd2875c..feab6c5 100644
--- a/src/jalv_gtk.c
+++ b/src/jalv_gtk.c
@@ -1108,9 +1108,11 @@ make_controller(ControlID* control, float value)
static GtkWidget*
new_label(const char* text, bool title, GtkAlign xalign, GtkAlign yalign)
{
- GtkWidget* label = gtk_label_new(NULL);
- const char* fmt = title ? "<span font_weight=\"bold\">%s</span>" : "%s:";
- gchar* str = g_markup_printf_escaped(fmt, text);
+ GtkWidget* const label = gtk_label_new(NULL);
+ gchar* const str =
+ title
+ ? g_markup_printf_escaped("<span font_weight=\"bold\">%s</span>", text)
+ : g_markup_printf_escaped("%s:", text);
gtk_widget_set_halign(label, xalign);
gtk_widget_set_valign(label, yalign);