aboutsummaryrefslogtreecommitdiffstats
path: root/src/empathy-chat-window.c
diff options
context:
space:
mode:
authorMathias Hasselmann <hasselmm@src.gnome.org>2008-11-14 06:07:54 +0800
committerMathias Hasselmann <hasselmm@src.gnome.org>2008-11-14 06:07:54 +0800
commitd3bb39fc883b0c4d53fe54469f2128456a820371 (patch)
tree6cb1af62c8be44ea61a952bc67872b1b1fc8adf0 /src/empathy-chat-window.c
parent2323398ad4771f85364efc56b03e976b4f1b4fa3 (diff)
downloadgsoc2013-empathy-d3bb39fc883b0c4d53fe54469f2128456a820371.tar
gsoc2013-empathy-d3bb39fc883b0c4d53fe54469f2128456a820371.tar.gz
gsoc2013-empathy-d3bb39fc883b0c4d53fe54469f2128456a820371.tar.bz2
gsoc2013-empathy-d3bb39fc883b0c4d53fe54469f2128456a820371.tar.lz
gsoc2013-empathy-d3bb39fc883b0c4d53fe54469f2128456a820371.tar.xz
gsoc2013-empathy-d3bb39fc883b0c4d53fe54469f2128456a820371.tar.zst
gsoc2013-empathy-d3bb39fc883b0c4d53fe54469f2128456a820371.zip
Use markup for chat-window tooltips
svn path=/trunk/; revision=1719
Diffstat (limited to 'src/empathy-chat-window.c')
-rw-r--r--src/empathy-chat-window.c31
1 files changed, 21 insertions, 10 deletions
diff --git a/src/empathy-chat-window.c b/src/empathy-chat-window.c
index a6b82dc0f..98a266141 100644
--- a/src/empathy-chat-window.c
+++ b/src/empathy-chat-window.c
@@ -355,7 +355,7 @@ chat_window_update_chat_tab (EmpathyChat *chat)
const gchar *subject;
GtkWidget *widget;
GString *tooltip;
- gchar *str;
+ gchar *markup;
const gchar *icon_name;
window = chat_window_find_chat (chat);
@@ -389,24 +389,35 @@ chat_window_update_chat_tab (EmpathyChat *chat)
/* Update tab tooltip */
tooltip = g_string_new (NULL);
+
if (remote_contact) {
- g_string_append_printf (tooltip, "%s\n%s",
- empathy_contact_get_id (remote_contact),
- empathy_contact_get_status (remote_contact));
+ markup = g_markup_printf_escaped ("<b>%s</b>\n%s",
+ empathy_contact_get_id (remote_contact),
+ empathy_contact_get_status (remote_contact));
+ g_string_append (tooltip, markup);
+ g_free (markup);
}
else {
- g_string_append (tooltip, name);
+ markup = g_markup_printf_escaped ("<b>%s</b>", name);
+ g_string_append (tooltip, markup);
+ g_free (markup);
}
+
if (subject) {
- g_string_append_printf (tooltip, "\n%s %s", _("Topic:"), subject);
+ markup = g_markup_printf_escaped ("\n<b>%s</b> %s", _("Topic:"), subject);
+ g_string_append (tooltip, markup);
+ g_free (markup);
}
if (g_list_find (priv->chats_composing, chat)) {
- g_string_append_printf (tooltip, "\n%s", _("Typing a message."));
+ markup = g_markup_printf_escaped ("\n%s", _("Typing a message."));
+ g_string_append (tooltip, markup);
+ g_free (markup);
}
- str = g_string_free (tooltip, FALSE);
+
+ markup = g_string_free (tooltip, FALSE);
widget = g_object_get_data (G_OBJECT (chat), "chat-window-tab-tooltip-widget");
- gtk_widget_set_tooltip_text (widget, str);
- g_free (str);
+ gtk_widget_set_tooltip_markup (widget, markup);
+ g_free (markup);
/* Update tab label */
widget = g_object_get_data (G_OBJECT (chat), "chat-window-tab-label");