GtkTextChildAnchor *anchor;
GtkWidget *box;
gchar *str;
- time_t time;
+ time_t time_;
gchar *tmp;
GtkTextIter start;
gboolean color_set;
GtkTextTagTable *table;
GtkTextTag *tag;
+ GString *str_obj;
contact = empathy_message_get_sender (msg);
name = empathy_contact_get_name (contact);
g_free (str);
/* Add the message receive time */
- time = empathy_message_get_timestamp (msg);
- tmp = empathy_time_to_string_local (time,
+ time_ = empathy_message_get_timestamp (msg);
+ tmp = empathy_time_to_string_local (time_,
EMPATHY_TIME_FORMAT_DISPLAY_SHORT);
str = g_strdup_printf ("<i>%s</i>", tmp);
label2 = g_object_new (GTK_TYPE_LABEL,
"use-markup", TRUE,
"xalign", 1.0,
NULL);
+
+ str_obj = g_string_new ("\n- ");
+ g_string_append (str_obj, name);
+ g_string_append (str_obj, ", ");
+ g_string_append (str_obj, tmp);
+ g_string_append (str_obj, " -");
g_free (tmp);
g_free (str);
gtk_box_pack_start (GTK_BOX (box), label2, TRUE, TRUE, 0);
/* Add the header box to the text view */
+ g_object_set_data_full (G_OBJECT (box),
+ "str_obj",
+ g_string_free (str_obj, FALSE),
+ g_free);
gtk_text_view_add_child_at_anchor (GTK_TEXT_VIEW (view),
box,
anchor);