GNOME Bugzilla – Bug 452949
Mark GError messages as translatable
Last modified: 2018-04-14 23:56:30 UTC
Mark GError messages as translatable, quite a few untranslated g_set_error() calls went into trunk together with gtkbuilder. Will attach a patch which marks them as translatable.
Created attachment 90995 [details] [review] patch
Why wasn't this committed?
Patch doesn't apply anymore :-(
Created attachment 142460 [details] [review] localize strings, updated
Created attachment 256557 [details] [review] localize strings, updated again Updated patch once again adding more strings to be localised
Created attachment 256683 [details] [review] v2 localize strings, updated again Some whitespace fixes
Review of attachment 256683 [details] [review]: @@ -2051,7 +2051,7 @@ gtk_builder_value_from_string_type (GtkBuilder *builder, { GtkIconTheme *theme; - g_warning ("Could not load image '%s': %s", + g_warning ("Could not load image '%s': %s", string, tmp_error->message); g_error_free (tmp_error); should be @@ -2051,7 +2051,7 @@ gtk_builder_value_from_string_type (GtkBuilder *builder, { GtkIconTheme *theme; - g_warning ("Could not load image '%s': %s", + g_warning (_("Could not load image '%s': %s"), string, tmp_error->message); g_error_free (tmp_error);
(In reply to comment #7) > Review of attachment 256683 [details] [review]: > > @@ -2051,7 +2051,7 @@ gtk_builder_value_from_string_type (GtkBuilder > *builder, > { > GtkIconTheme *theme; > > - g_warning ("Could not load image '%s': %s", > + g_warning ("Could not load image '%s': %s", > string, tmp_error->message); > g_error_free (tmp_error); > > should be > > @@ -2051,7 +2051,7 @@ gtk_builder_value_from_string_type (GtkBuilder > *builder, > { > GtkIconTheme *theme; > > - g_warning ("Could not load image '%s': %s", > + g_warning (_("Could not load image '%s': %s"), > string, tmp_error->message); > g_error_free (tmp_error); There are a bunch of untranslated warning strings in that file. This patch is mainly about translating g_set_error() strings. The line you point to just removes an extra white space. Maybe I could provide a separate patch that marks all the warnings for translation too, would that be useful?? I understand there is one warning that is marked for translation at the end of the patch I'm not really sure why that one was chosen for translation and not the rest I just did the same thing as in the previous patch.
I'm not convinced anymore that translating warnings is useful at all.
We're moving to gitlab! As part of this move, we are moving bugs to NEEDINFO if they haven't seen activity in more than a year. If this issue is still important to you and still relevant with GTK+ 3.22 or master, please reopen it and we will migrate it to gitlab.
As announced a while ago, we are migrating to gitlab, and bugs that haven't seen activity in the last year or so will be not be migrated, but closed out in bugzilla. If this bug is still relevant to you, you can open a new issue describing the symptoms and how to reproduce it with gtk 3.22.x or master in gitlab: https://gitlab.gnome.org/GNOME/gtk/issues/new