Skip to content
Snippets Groups Projects
Commit 580c8938 authored by Harald Judt's avatar Harald Judt Committed by Eric Koegel
Browse files

Battery plugin: Allow markup in scalemenuitem description label

parent e4582c28
No related branches found
No related tags found
No related merge requests found
......@@ -922,7 +922,7 @@ battery_button_show_menu (BatteryButton *button)
gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM(mi), img);
}
scale_menu_item_set_description_label (SCALE_MENU_ITEM(mi), _("Display brightness"));
scale_menu_item_set_description_label (SCALE_MENU_ITEM(mi), _("<b>Display brightness</b>"));
/* range slider */
button->priv->range = scale_menu_item_get_scale (SCALE_MENU_ITEM (mi));
......
......@@ -501,12 +501,14 @@ scale_menu_item_set_description_label (ScaleMenuItem *menuitem,
if (priv->description_label && label)
{
gtk_label_set_text (GTK_LABEL (priv->description_label), label);
gtk_label_set_markup (GTK_LABEL (priv->description_label), label);
}
else if(label)
{
/* create label */
priv->description_label = gtk_label_new (label);
priv->description_label = gtk_label_new (NULL);
gtk_label_set_markup (GTK_LABEL (priv->description_label), label);
/* align left */
gtk_misc_set_alignment (GTK_MISC(priv->description_label), 0, 0);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment