After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 628193 - Miscellaneous string fixes
Miscellaneous string fixes
Status: RESOLVED FIXED
Product: glib
Classification: Platform
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: gtkdev
gtkdev
Depends on:
Blocks:
 
 
Reported: 2010-08-28 15:17 UTC by Philip Withnall
Modified: 2012-08-17 03:06 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Miscellaneous string fixes (17.32 KB, patch)
2010-08-28 15:19 UTC, Philip Withnall
needs-work Details | Review
Make capitalisation of "Unix" consistent (4.85 KB, patch)
2010-08-28 15:20 UTC, Philip Withnall
rejected Details | Review
Change "lock-file" to "lock file" (2.62 KB, patch)
2010-08-28 15:21 UTC, Philip Withnall
committed Details | Review
Change "type-string" to "type string" (1.36 KB, patch)
2010-08-28 15:21 UTC, Philip Withnall
committed Details | Review
Change "dash" to "hyphen" (1.71 KB, patch)
2010-08-28 15:22 UTC, Philip Withnall
committed Details | Review
Make capitalisation of "UNIX" consistent in translatable strings (5.19 KB, patch)
2010-08-30 21:20 UTC, Philip Withnall
committed Details | Review
Miscellaneous string fixes (updated) (9.71 KB, patch)
2010-08-30 21:38 UTC, Philip Withnall
none Details | Review

Description Philip Withnall 2010-08-28 15:17:24 UTC
Set of five patches coming up with some string fixes. If they're OK, these would ideally be committed this weekend, since the string freeze is coming into effect on Monday.
Comment 1 Philip Withnall 2010-08-28 15:19:33 UTC
Created attachment 168945 [details] [review]
Miscellaneous string fixes

Some capitalisation fixes, removal of extraneous commas, replacement of commas and hyphens with colons where it's more appropriate, a few missing words and some typo fixes.
Comment 2 Philip Withnall 2010-08-28 15:20:34 UTC
Created attachment 168946 [details] [review]
Make capitalisation of "Unix" consistent

The convention in GLib's translatable strings is to capitalise the operating system as "Unix", not "UNIX" or "unix". This applies that convention to some new strings.
Comment 3 Philip Withnall 2010-08-28 15:21:08 UTC
Created attachment 168947 [details] [review]
Change "lock-file" to "lock file"

There's no need for "lock-file" to be hyphenated.
Comment 4 Philip Withnall 2010-08-28 15:21:49 UTC
Created attachment 168948 [details] [review]
Change "type-string" to "type string"

Neither is there a need for "type-string" to be hyphenated unless it's a technical term, in which case it might need quotation marks instead.
Comment 5 Philip Withnall 2010-08-28 15:22:22 UTC
Created attachment 168949 [details] [review]
Change "dash" to "hyphen"

The character which is used in GSchema files is a hyphen, not a dash.
Comment 6 Matthias Clasen 2010-08-28 21:26:31 UTC
(In reply to comment #2)
> Created an attachment (id=168946) [details] [review]
> Make capitalisation of "Unix" consistent
> 
> The convention in GLib's translatable strings is to capitalise the operating
> system as "Unix", not "UNIX" or "unix". This applies that convention to some
> new strings.

This is not true, actually. We try to use UNIX, not Unix or unix.
Comment 7 Matthias Clasen 2010-08-28 21:44:57 UTC
Review of attachment 168945 [details] [review]:

I don't think most of the 'replace - or , by :' style changes are worth the churn, and I don't see why ID is better than id. 
Some of the other fixes are fine.

::: gio/gdbusaddress.c
@@ +243,3 @@
                        G_IO_ERROR,
                        G_IO_ERROR_INVALID_ARGUMENT,
+                       _("Error in address `%s': the port attribute is malformed"),

I don't think these are fixes, really. Just a different style.

@@ +432,3 @@
                    G_IO_ERROR,
                    G_IO_ERROR_INVALID_ARGUMENT,
+                   _("Address element `%s' does not contain a colon (:)"),

This one is obviously correct

@@ +453,3 @@
                        G_IO_ERROR,
                        G_IO_ERROR_INVALID_ARGUMENT,
+                       _("Key/Value pair %d, `%s', in address element `%s' does not contain an equal sign"),

Here I think if you want to remove commas, you need to remove the comma before 'in' as well.

@@ +1057,3 @@
                    G_IO_ERROR,
                    G_IO_ERROR_FAILED,
+                   _("Abnormal program termination when spawning command line `%s': %s"),

This looks ok.

::: gio/gdbusauthmechanismsha1.c
@@ +456,3 @@
                G_IO_ERROR,
                G_IO_ERROR_FAILED,
+               _("Didn't find cookie with ID %d in the keyring at `%s'"),

I don't think this makes sense. Why is ID better than id ?

::: gio/gdbusmethodinvocation.c
@@ +373,3 @@
           gchar *type_string = g_variant_type_dup_string (type);
 
+          g_warning (_("Type of return value is incorrect: got `%s', expected `%s'"),

I agree that this is an improvement.

::: gio/gicon.c
@@ +431,1 @@
     }

Ok

::: gio/gschema-compile.c
@@ +1049,1 @@
                          "existing schema '%s'"), id, extends_name);

Awkward linebreak now. If we go with this, the 'existing' should be moved to the previous line

@@ +1060,3 @@
           g_set_error (error, G_MARKUP_ERROR,
                        G_MARKUP_ERROR_INVALID_CONTENT,
+                       _("<schema id='%s'> is list of not-yet-"

Ditto

@@ +1341,3 @@
   else
     g_set_error (error, G_MARKUP_ERROR, G_MARKUP_ERROR_UNKNOWN_ELEMENT,
+                 _("Element <%s> not allowed at the top level"), element_name);

This is better

@@ +1707,3 @@
                                    G_MARKUP_ERROR_INVALID_CONTENT,
                                    _("override for key `%s' in schema `%s' in "
+                                     "override file `%s' is outside the range "

Ok

::: gio/gsettings-tool.c
@@ +233,3 @@
   g_option_context_set_description (context,
     _("Arguments:\n"
+      "  SCHEMA      The ID of the schema\n"

Again, I don't buy this

@@ +336,2 @@
       "  KEY         The name of the key\n"
+      "  VALUE       The value to set the key to, as a serialized GVariant\n"));

ok

::: gio/gsocket.c
@@ +2992,3 @@
       {
         g_set_error_literal (error, G_IO_ERROR, G_IO_ERROR_NOT_SUPPORTED,
+                             _("GSocketControlMessage not supported on Windows"));

ok

::: gio/gsocketclient.c
@@ +709,3 @@
               g_set_error_literal (&last_error,
                   G_IO_ERROR, G_IO_ERROR_NOT_SUPPORTED,
+                  _("Trying to proxy over a non-TCP connection is not supported."));

I think this should be shortened to 'Proxying over a non-TCP connection is not supported'

::: gio/gsocks5proxy.c
@@ +177,3 @@
       default:
 	g_set_error_literal (error, G_IO_ERROR, G_IO_ERROR_PROXY_AUTH_FAILED,
+			     _("The SOCKSv5 proxy requires an authentication method that is not "

ok

@@ +350,3 @@
 	  default:
 	    g_set_error_literal (error, G_IO_ERROR, G_IO_ERROR_PROXY_FAILED,
+			   _("The SOCKSv5 proxy server uses an unknown address type."));

ok

@@ +400,3 @@
       default: /* Unknown error */
 	g_set_error_literal (error, G_IO_ERROR, G_IO_ERROR_PROXY_FAILED,
+			     _("Unknown SOCKSv5 proxy error."));

no change ?

::: glib/gmarkup.c
@@ +1119,3 @@
                                error,
                                G_MARKUP_ERROR_PARSE,
+                               _("Odd character '%s': expected a '>' character "

I don't think this is a sufficient improvement to justify the churn.

::: glib/gregex.c
@@ +256,3 @@
       break;
     case G_REGEX_ERROR_UNRECOGNIZED_ESCAPE:
+      *errmsg = _("unrecognized character following \\");

ok
Comment 8 Matthias Clasen 2010-08-28 21:45:37 UTC
Review of attachment 168946 [details] [review]:

We actually try to use UNIX in the documentation.
Comment 9 Matthias Clasen 2010-08-28 21:46:51 UTC
Review of attachment 168947 [details] [review]:

::: gio/gdbusauthmechanismsha1.c
@@ +525,3 @@
       if (num_tries == 50)
         {
+          /* ok, we slept 50*10ms = 0.5 seconds.. Conclude that the lock file must be

If you touch this, remove the doubled . as well.
Comment 10 Matthias Clasen 2010-08-28 21:47:18 UTC
Review of attachment 168948 [details] [review]:

ok
Comment 11 Philip Withnall 2010-08-28 23:27:15 UTC
(In reply to comment #7)
> Review of attachment 168945 [details] [review]:
> 
> I don't think most of the 'replace - or , by :' style changes are worth the
> churn, and I don't see why ID is better than id. 
> Some of the other fixes are fine.

If I separate out the 'replace - or , by :' into a separate patch, could it be applied after GLib next branches? They're definitely correct changes unless you want to change policy and use (Unicode) em-dashes instead of the hyphens. As it stands, the strings are incorrectly using a hyphen as an em-dash, and the only appropriate ASCII character which serves the same purpose is a colon.

"ID" is an abbreviation for "identification", whereas "id" is a psychology term. See: http://dictionary.reference.com/browse/id. It's convention to show that "ID" is an abbreviation by capitalising it (as opposed to using a full stop or apostrophe to show it's abbreviated; got to love English).

Thanks for the fast review.

> @@ +453,3 @@
>                         G_IO_ERROR,
>                         G_IO_ERROR_INVALID_ARGUMENT,
> +                       _("Key/Value pair %d, `%s', in address element `%s'
> does not contain an equal sign"),
> 
> Here I think if you want to remove commas, you need to remove the comma before
> 'in' as well.

In the absence of a translator comment or something to give the format of what's substituted into the second parameter (kv_pair), I think the comma before 'in' is correct. As I read it, the second parameter is written as an aside, so needs parenthetical commas (or brackets) around it. Please correct me if I'm wrong.

> ::: gio/gdbusauthmechanismsha1.c
> @@ +456,3 @@
>                 G_IO_ERROR,
>                 G_IO_ERROR_FAILED,
> +               _("Didn't find cookie with ID %d in the keyring at `%s'"),
> 
> I don't think this makes sense. Why is ID better than id ?

See above.

> ::: gio/gschema-compile.c
> @@ +1049,1 @@
>                           "existing schema '%s'"), id, extends_name);
> 
> Awkward linebreak now. If we go with this, the 'existing' should be moved to
> the previous line

OK.

> @@ +1060,3 @@
>            g_set_error (error, G_MARKUP_ERROR,
>                         G_MARKUP_ERROR_INVALID_CONTENT,
> +                       _("<schema id='%s'> is list of not-yet-"
> 
> Ditto

OK.

> ::: gio/gsocketclient.c
> @@ +709,3 @@
>                g_set_error_literal (&last_error,
>                    G_IO_ERROR, G_IO_ERROR_NOT_SUPPORTED,
> +                  _("Trying to proxy over a non-TCP connection is not
> supported."));
> 
> I think this should be shortened to 'Proxying over a non-TCP connection is not
> supported'

Makes sense.

> @@ +400,3 @@
>        default: /* Unknown error */
>      g_set_error_literal (error, G_IO_ERROR, G_IO_ERROR_PROXY_FAILED,
> +                 _("Unknown SOCKSv5 proxy error."));
> 
> no change ?

The origin string had "unkown" instead of "unknown".

> ::: glib/gmarkup.c
> @@ +1119,3 @@
>                                 error,
>                                 G_MARKUP_ERROR_PARSE,
> +                               _("Odd character '%s': expected a '>' character
> "
> 
> I don't think this is a sufficient improvement to justify the churn.

Shall I separate out into a patch which can be applied after branching?
Comment 12 Philip Withnall 2010-08-28 23:33:24 UTC
(In reply to comment #8)
> Review of attachment 168946 [details] [review]:
> 
> We actually try to use UNIX in the documentation.

I'm sure I remember doing a string fix patch for either GLib or GTK+ a while (two cycles?) ago which standardised on "Unix"…but I can't find any evidence of it now. Maybe my mind's playing tricks on me. Sorry.

Shall I re-do the patch with s/Unix/UNIX/?
Comment 13 Philip Withnall 2010-08-28 23:39:51 UTC
Comment on attachment 168947 [details] [review]
Change "lock-file" to "lock file"

Committed with the comment fix.
Comment 14 Philip Withnall 2010-08-28 23:40:35 UTC
Comment on attachment 168948 [details] [review]
Change "type-string" to "type string"

I'll send a string notification e-mail now with a warning that there might be more changes coming from this bug.
Comment 15 Matthias Clasen 2010-08-30 14:07:32 UTC
(In reply to comment #12)
> (In reply to comment #8)
> > Review of attachment 168946 [details] [review] [details]:
> > 
> > We actually try to use UNIX in the documentation.
> 
> I'm sure I remember doing a string fix patch for either GLib or GTK+ a while
> (two cycles?) ago which standardised on "Unix"…but I can't find any evidence of
> it now. Maybe my mind's playing tricks on me. Sorry.
> 

I can find this: 

commit a3d7806b6d2861d100bbd79934c2c010a9242808
Author: Matthias Clasen <matthiasc@src.gnome.org>
Date:   Thu Dec 13 22:24:18 2001 +0000

    Revert mistaken change: it is UNIX, not Unix.


That is admittedly old.
Comment 16 Philip Withnall 2010-08-30 21:20:44 UTC
Created attachment 169130 [details] [review]
Make capitalisation of "UNIX" consistent in translatable strings

Here's an updated patch to make capitalisation of "UNIX" consistent. There's still time to get it in before the string freeze at midnight tonight, if you want to.
Comment 17 Philip Withnall 2010-08-30 21:38:17 UTC
Created attachment 169131 [details] [review]
Miscellaneous string fixes (updated)

Updated version of the first patch containing only the accepted changes.

Any thoughts about attachment #168949 [details]?

I'll do another patch with the ID and hyphen-to-colon changes once a decision has been reached over them.
Comment 18 Philip Withnall 2010-12-26 12:39:14 UTC
Ping?
Comment 19 Matthias Clasen 2012-03-18 03:04:56 UTC
Sorry for letting this slide for so long - I'll pick this patch up once we open the 2.33 cycle
Comment 20 Matthias Clasen 2012-08-17 02:23:37 UTC
Review of attachment 168949 [details] [review]:

.
Comment 21 Matthias Clasen 2012-08-17 02:47:59 UTC
Review of attachment 169130 [details] [review]:

Most of this patch was obsoleted, but I've applied the gunixsocketaddress part