r14940 - gnucash/trunk/src/gnome - Avoid markup in translatable messages. Bug#360459

Derek Atkins warlord at MIT.EDU
Fri Nov 24 16:56:17 EST 2006


Christian,

Should this get back-ported to 2.0?

-derek

Christian Stimming <cstim at cvs.gnucash.org> writes:

> Author: cstim
> Date: 2006-10-09 07:45:48 -0400 (Mon, 09 Oct 2006)
> New Revision: 14940
> Trac: http://svn.gnucash.org/trac/changeset/14940
>
> Modified:
>    gnucash/trunk/src/gnome/druid-hierarchy.c
> Log:
> Avoid markup in translatable messages. Bug#360459
>
> Modified: gnucash/trunk/src/gnome/druid-hierarchy.c
> ===================================================================
> --- gnucash/trunk/src/gnome/druid-hierarchy.c	2006-10-08 20:14:35 UTC (rev 14939)
> +++ gnucash/trunk/src/gnome/druid-hierarchy.c	2006-10-09 11:45:48 UTC (rev 14940)
> @@ -476,9 +476,13 @@
>  
>  	/* Add a new one if something selected */
>  	if (gtk_tree_selection_get_selected (selection, &model, &iter)) {
> +		gchar *text2;
>  		gtk_tree_model_get (model, &iter, COL_ACCOUNT, &gea, -1);
> -		text = g_strdup_printf(_("<b>Accounts in '%s'</b>"), gea->title);
> +		/* Translators: '%s' is the name of the selected account hierarchy template. */
> +		text2 = g_strdup_printf(_("Accounts in '%s'"), gea->title);
> +		text = g_strdup_printf("<b>%s</b>", text2);
>  		gtk_label_set_markup(data->category_accounts_label, text);
> +		g_free(text2);
>  		g_free(text);
>  		buffer = gtk_text_view_get_buffer(data->category_description);
>  		gtk_text_buffer_set_text(buffer, gea->long_description, -1);
> @@ -493,8 +497,10 @@
>  		gtk_container_add(GTK_CONTAINER(data->category_accounts_container), GTK_WIDGET(tree_view));
>  		gtk_widget_show(GTK_WIDGET(tree_view));
>  	} else {
> -		gtk_label_set_markup(data->category_accounts_label,
> -				     _("<b>Accounts in Category</b>"));
> +		gchar *text;
> +		text = g_strdup_printf ("<b>%s</b>", _("Accounts in Category"));
> +		gtk_label_set_markup(data->category_accounts_label, text);
> +		g_free (text);
>  		buffer = gtk_text_view_get_buffer(data->category_description);
>  		gtk_text_buffer_set_text(buffer, "", -1);
>  	}
>
> _______________________________________________
> gnucash-changes mailing list
> gnucash-changes at gnucash.org
> https://lists.gnucash.org/mailman/listinfo/gnucash-changes
>
>

-- 
       Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
       Member, MIT Student Information Processing Board  (SIPB)
       URL: http://web.mit.edu/warlord/    PP-ASEL-IA     N1NWH
       warlord at MIT.EDU                        PGP key available


More information about the gnucash-devel mailing list