diff options
author | Ted Gould <ted@canonical.com> | 2009-08-26 20:46:43 -0500 |
---|---|---|
committer | Ted Gould <ted@canonical.com> | 2009-08-26 20:46:43 -0500 |
commit | 1077ceea42e73c4c9ef0f368913f18a9a3b092f8 (patch) | |
tree | 48b1e03e8c0de87cdb4e8d80ed79fcd85650c7de /src/indicator-messages.c | |
parent | d08632f2c21df15c8edf292910d63f144bb4a7a3 (diff) | |
download | ayatana-indicator-messages-1077ceea42e73c4c9ef0f368913f18a9a3b092f8.tar.gz ayatana-indicator-messages-1077ceea42e73c4c9ef0f368913f18a9a3b092f8.tar.bz2 ayatana-indicator-messages-1077ceea42e73c4c9ef0f368913f18a9a3b092f8.zip |
Adding a little style to our labels. Hopefully making them look a little nicer.
Diffstat (limited to 'src/indicator-messages.c')
-rw-r--r-- | src/indicator-messages.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/indicator-messages.c b/src/indicator-messages.c index 8838313..0a1002d 100644 --- a/src/indicator-messages.c +++ b/src/indicator-messages.c @@ -21,6 +21,7 @@ with this program. If not, see <http://www.gnu.org/licenses/>. */ #include <string.h> +#include <glib.h> #include <gtk/gtk.h> #include <libdbusmenu-gtk/menu.h> #include <dbus/dbus-glib.h> @@ -144,7 +145,13 @@ new_launcher_item (DbusmenuMenuitem * newitem, DbusmenuMenuitem * parent, Dbusme GtkWidget * vbox = gtk_vbox_new(TRUE, 2); GtkWidget * app_label = gtk_label_new(dbusmenu_menuitem_property_get(newitem, LAUNCHER_MENUITEM_PROP_APP_NAME)); - GtkWidget * dsc_label = gtk_label_new(dbusmenu_menuitem_property_get(newitem, LAUNCHER_MENUITEM_PROP_APP_DESC)); + gtk_misc_set_alignment(GTK_MISC(app_label), 0.0, 0.5); + GtkWidget * dsc_label = gtk_label_new(""); + gtk_misc_set_alignment(GTK_MISC(dsc_label), 0.05, 0.5); + gtk_label_set_ellipsize(GTK_LABEL(dsc_label), PANGO_ELLIPSIZE_END); + gchar * markup = g_markup_printf_escaped("<span font-size=\"smaller\">%s</span>", dbusmenu_menuitem_property_get(newitem, LAUNCHER_MENUITEM_PROP_APP_DESC)); + gtk_label_set_markup(GTK_LABEL(dsc_label), markup); + g_free(markup); gtk_box_pack_start(GTK_BOX(vbox), app_label, FALSE, FALSE, 0); gtk_widget_show(app_label); |