Bug 21995 - Use msgctxt instead of comments
Summary: Use msgctxt instead of comments
Status: RESOLVED WONTFIX
Alias: None
Product: PackageKit
Classification: Unclassified
Component: General (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Richard Hughes
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-05-29 07:00 UTC by Gil Forcada
Modified: 2009-06-03 09:28 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gil Forcada 2009-05-29 07:00:20 UTC
It's a great pleasure to translate an application with comments in each string, but it would be better if this comments are converted to msgctxt so applications should take advantage of it when you are translating.

See http://live.gnome.org/GnomeGoals/MsgctxtMigration
Comment 1 Richard Hughes 2009-05-29 07:16:13 UTC
I don't think we use Q_ anywhere in PackageKit... do you mean do something like this? That seems like a lot of work...

diff --git a/client/pk-console.c b/client/pk-console.c
index 1d8df81..add804a 100644
--- a/client/pk-console.c
+++ b/client/pk-console.c
@@ -1930,8 +1930,7 @@ main (int argc, char *argv[])
 
                } else if (strcmp (value, "group") == 0) {
                        if (details == NULL) {
-                               /* TRANSLATORS: the user needs to provide a search term */
-                               error = g_error_new (1, 0, "%s", _("A search term is required"));
+                               error = g_error_new (1, 0, "%s", C_("A search term is required", "the user needs to provide a search term"));
                                goto out;
                        }
                        ret = pk_client_search_group (client_async, filters, details, &error);

Comment 2 Gil Forcada 2009-05-29 08:10:26 UTC
(In reply to comment #1)
> I don't think we use Q_ anywhere in PackageKit... do you mean do something like
> this? That seems like a lot of work...
> 

Sure it's a lot of work, there are +700 strings and +500 of them have comments, but it's quite useless right now if you are not translating with plain text editors (like gedit, vim, emacs and so on) since everything that is not msgid or msgstr is visually stripped in editors like Gtranslator, Kbabel, Poedit ...

Adding the msgctxt ensures that everyone, no matter which editor uses will see your comments and thus will be able to translate properly your app.

Comment 3 Gil Forcada 2009-06-03 07:34:35 UTC
Bones,

Tenim un concert a mitja tarda i jo a més haig d'anar a votar a Osona :S

Salut!

El dv 29 de 05 de 2009 a les 07:16 -0700, en/na
bugzilla-daemon@freedesktop.org va escriure:
> http://bugs.freedesktop.org/show_bug.cgi?id=21995
> 
> 
> 
> 
> 
> --- Comment #1 from Richard Hughes <richard@hughsie.com>  2009-05-29 07:16:13 PST ---
> I don't think we use Q_ anywhere in PackageKit... do you mean do something like
> this? That seems like a lot of work...
> 
> diff --git a/client/pk-console.c b/client/pk-console.c
> index 1d8df81..add804a 100644
> --- a/client/pk-console.c
> +++ b/client/pk-console.c
> @@ -1930,8 +1930,7 @@ main (int argc, char *argv[])
> 
>                 } else if (strcmp (value, "group") == 0) {
>                         if (details == NULL) {
> -                               /* TRANSLATORS: the user needs to provide a
> search term */
> -                               error = g_error_new (1, 0, "%s", _("A search
> term is required"));
> +                               error = g_error_new (1, 0, "%s", C_("A search
> term is required", "the user needs to provide a search term"));
>                                 goto out;
>                         }
>                         ret = pk_client_search_group (client_async, filters,
> details, &error);
> 
> 
Comment 4 Richard Hughes 2009-06-03 09:28:10 UTC
I've talked a bit to other people about this. The basic message is that msgctx
are different from translator comments. The msgctx is only useful to
differentiate the same mgsid, and the comments should be a help to the
translator when they are being translated. I see the translator comments in
Gtranslator -- maybe it's a intltool issue you're seeing?

Anyway, I don't think converting all the comments into msgctx's is a good idea
for now, sorry.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.