[empathy: 73/80] Use some markup to make the logs more readable
- From: Emilio Pozuelo Monfort <epm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [empathy: 73/80] Use some markup to make the logs more readable
- Date: Fri, 10 Jun 2011 08:45:17 +0000 (UTC)
commit e44cdbfd3407bb6801fed763da5ae3c332305d12
Author: Danielle Madeley <danielle madeley collabora co uk>
Date: Fri May 27 15:48:21 2011 +1000
Use some markup to make the logs more readable
Emotes are in italics. Sender's names are in bold.
Mark emotes for translation since we've done that for messages.
libempathy-gtk/empathy-log-window.c | 12 +++++++-----
1 files changed, 7 insertions(+), 5 deletions(-)
---
diff --git a/libempathy-gtk/empathy-log-window.c b/libempathy-gtk/empathy-log-window.c
index bd27568..6088874 100644
--- a/libempathy-gtk/empathy-log-window.c
+++ b/libempathy-gtk/empathy-log-window.c
@@ -739,7 +739,7 @@ get_parent_iter_for_message (TplEvent *event,
pretty_date = g_date_time_format (date,
C_("A date with the time", "%A, %e %B %Y %X"));
- body = g_strdup_printf (_("Chat with %s"),
+ body = g_markup_printf_escaped (_("Chat with %s"),
get_contact_alias_for_message (message));
gtk_tree_store_append (store, &iter, NULL);
@@ -803,14 +803,16 @@ log_window_append_chat_message (TplEvent *event,
if (tpl_text_event_get_message_type (TPL_TEXT_EVENT (event))
== TP_CHANNEL_TEXT_MESSAGE_TYPE_ACTION)
{
- body = g_strdup_printf ("* %s %s",
+ /* Translators: this is an emote: '* Danielle waves' */
+ body = g_markup_printf_escaped (_("<i>* %s %s</i>"),
tpl_entity_get_alias (tpl_event_get_sender (event)),
empathy_message_get_body (message));
}
else
{
- body = g_strdup_printf (
- C_("First is a contact, second is what was said", "%s: %s"),
+ /* Translators: this is a message: 'Danielle: hello'
+ * The string in bold is the sender's name */
+ body = g_markup_printf_escaped (_("<b>%s:</b> %s"),
tpl_entity_get_alias (tpl_event_get_sender (event)),
empathy_message_get_body (message));
}
@@ -1885,7 +1887,7 @@ log_window_events_setup (EmpathyLogWindow *window)
cell = gtk_cell_renderer_text_new ();
gtk_tree_view_column_pack_start (column, cell, TRUE);
gtk_tree_view_column_add_attribute (column, cell,
- "text", COL_EVENTS_TEXT);
+ "markup", COL_EVENTS_TEXT);
cell = gtk_cell_renderer_text_new ();
g_object_set (cell, "xalign", 1.0, NULL);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]