]> granicus.if.org Git - handbrake/commitdiff
LinGui: fix display of preset name on ubuntu trusty
authorJohn Stebbins <jstebbins.hb@gmail.com>
Wed, 27 Jun 2018 21:09:07 +0000 (14:09 -0700)
committerJohn Stebbins <jstebbins.hb@gmail.com>
Wed, 27 Jun 2018 21:09:07 +0000 (14:09 -0700)
Pango on trusty doesn't understand the "alpha" span attribute and fails
to format and display preset name.

gtk/src/presets.c

index 58e9da11ca63968b467ca21684258f4dbbc8cad1..f5e6eabf92c7c5a3a0977e4be6ff6d57c2f848c7 100644 (file)
@@ -542,7 +542,12 @@ set_preset_menu_button_label(signal_user_data_t *ud, hb_preset_index_t *path)
 
     dict = hb_preset_get(path);
     type = ghb_dict_get_int(dict, "Type");
+
+#if PANGO_VERSION_CHECK(1, 38, 0)
     fullname = preset_get_fullname(path, " <span alpha=\"70%\">></span> ");
+#else
+    fullname = preset_get_fullname(path, " > ");
+#endif
     label = GTK_LABEL(GHB_WIDGET(ud->builder, "presets_menu_button_label"));
     text = g_strdup_printf("%s%s", type == HB_PRESET_TYPE_CUSTOM ?
                                    "Custom" : "Official", fullname);