From 0bb3cacacbf5bffd920b357a82254f1e170a4c83 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Piotr=20Dr=C4=85g?= Date: Sat, 5 Nov 2016 13:03:35 +0100 Subject: [PATCH 1/2] Fix tests for Unicode strings Based on a patch by Simon McVittie . Fixes: https://gitlab.gnome.org/GNOME/glib/issues/1212 --- glib/tests/markups/fail-10.expected | 2 +- glib/tests/markups/fail-11.expected | 2 +- glib/tests/markups/fail-12.expected | 2 +- glib/tests/markups/fail-13.expected | 2 +- glib/tests/markups/fail-14.expected | 2 +- glib/tests/markups/fail-15.expected | 2 +- glib/tests/markups/fail-22.expected | 2 +- glib/tests/markups/fail-26.expected | 2 +- glib/tests/markups/fail-27.expected | 2 +- glib/tests/markups/fail-28.expected | 2 +- glib/tests/markups/fail-29.expected | 2 +- glib/tests/markups/fail-3.expected | 4 ++-- glib/tests/markups/fail-30.expected | 2 +- glib/tests/markups/fail-31.expected | 2 +- glib/tests/markups/fail-32.expected | 2 +- glib/tests/markups/fail-33.expected | 2 +- glib/tests/markups/fail-34.expected | 2 +- glib/tests/markups/fail-35.expected | 2 +- glib/tests/markups/fail-36.expected | 2 +- glib/tests/markups/fail-37.expected | 2 +- glib/tests/markups/fail-38.expected | 2 +- glib/tests/markups/fail-39.expected | 2 +- glib/tests/markups/fail-40.expected | 2 +- glib/tests/markups/fail-41.expected | 2 +- glib/tests/markups/fail-42.expected | 2 +- glib/tests/markups/fail-43.expected | 2 +- glib/tests/markups/fail-44.expected | 2 +- glib/tests/markups/fail-45.expected | 2 +- glib/tests/markups/fail-46.expected | 2 +- glib/tests/markups/fail-47.expected | 2 +- glib/tests/markups/fail-48.expected | 2 +- glib/tests/markups/fail-49.expected | 2 +- glib/tests/markups/fail-5.expected | 2 +- glib/tests/markups/fail-6.expected | 2 +- glib/tests/markups/fail-7.expected | 2 +- glib/tests/markups/fail-8.expected | 2 +- glib/tests/markups/fail-9.expected | 2 +- 37 files changed, 38 insertions(+), 38 deletions(-) diff --git a/glib/tests/markups/fail-10.expected b/glib/tests/markups/fail-10.expected index 7761a2262..6462cdf8c 100644 --- a/glib/tests/markups/fail-10.expected +++ b/glib/tests/markups/fail-10.expected @@ -1,4 +1,4 @@ ELEMENT 'foo' TEXT ' ' -ERROR Error on line 2 char 8: Element '|foo' was closed, but the currently open element is 'foo' +ERROR Error on line 2 char 8: Element “|foo” was closed, but the currently open element is “foo” diff --git a/glib/tests/markups/fail-11.expected b/glib/tests/markups/fail-11.expected index 3a7173d37..f2331b796 100644 --- a/glib/tests/markups/fail-11.expected +++ b/glib/tests/markups/fail-11.expected @@ -4,4 +4,4 @@ ELEMENT 'foo' ELEMENT 'bar' TEXT ' ' -ERROR Error on line 3 char 7: Element 'foo' was closed, but the currently open element is 'bar' +ERROR Error on line 3 char 7: Element “foo” was closed, but the currently open element is “bar” diff --git a/glib/tests/markups/fail-12.expected b/glib/tests/markups/fail-12.expected index 0aab7b5f1..c4176b08a 100644 --- a/glib/tests/markups/fail-12.expected +++ b/glib/tests/markups/fail-12.expected @@ -1 +1 @@ -ERROR Error on line 1 char 6: Element 'foo' was closed, no element is currently open +ERROR Error on line 1 char 6: Element “foo” was closed, no element is currently open diff --git a/glib/tests/markups/fail-13.expected b/glib/tests/markups/fail-13.expected index 60157fa4a..b2cdf9f46 100644 --- a/glib/tests/markups/fail-13.expected +++ b/glib/tests/markups/fail-13.expected @@ -1 +1 @@ -ERROR Error on line 1 char 7: Element 'foo|' was closed, no element is currently open +ERROR Error on line 1 char 7: Element “foo|” was closed, no element is currently open diff --git a/glib/tests/markups/fail-14.expected b/glib/tests/markups/fail-14.expected index 47e6847cc..2f0d64140 100644 --- a/glib/tests/markups/fail-14.expected +++ b/glib/tests/markups/fail-14.expected @@ -1,4 +1,4 @@ ELEMENT 'foo' TEXT ' ' -ERROR Error on line 2 char 3: Document ended unexpectedly just after an open angle bracket '<' +ERROR Error on line 2 char 3: Document ended unexpectedly just after an open angle bracket “<” diff --git a/glib/tests/markups/fail-15.expected b/glib/tests/markups/fail-15.expected index 380ab74d8..5b31870d4 100644 --- a/glib/tests/markups/fail-15.expected +++ b/glib/tests/markups/fail-15.expected @@ -5,4 +5,4 @@ ELEMENT 'foo' TEXT ' ' END 'bar' -ERROR Error on line 3 char 8: Document ended unexpectedly with elements still open - 'foo' was the last element opened +ERROR Error on line 3 char 8: Document ended unexpectedly with elements still open — “foo” was the last element opened diff --git a/glib/tests/markups/fail-22.expected b/glib/tests/markups/fail-22.expected index b9585de18..a238253d0 100644 --- a/glib/tests/markups/fail-22.expected +++ b/glib/tests/markups/fail-22.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 1 char 6: Document ended unexpectedly with elements still open - 'foo' was the last element opened +ERROR Error on line 1 char 6: Document ended unexpectedly with elements still open — “foo” was the last element opened diff --git a/glib/tests/markups/fail-26.expected b/glib/tests/markups/fail-26.expected index 99ab934bb..69392f093 100644 --- a/glib/tests/markups/fail-26.expected +++ b/glib/tests/markups/fail-26.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 1: Empty entity '&;' seen; valid entities are: & " < > ' +ERROR Error on line 1: Empty entity “&;” seen; valid entities are: & " < > ' diff --git a/glib/tests/markups/fail-27.expected b/glib/tests/markups/fail-27.expected index 3090f33f9..8d70804ed 100644 --- a/glib/tests/markups/fail-27.expected +++ b/glib/tests/markups/fail-27.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 1: Entity name '|' is not known +ERROR Error on line 1: Entity name “|” is not known diff --git a/glib/tests/markups/fail-28.expected b/glib/tests/markups/fail-28.expected index e54ab6615..fa1171c66 100644 --- a/glib/tests/markups/fail-28.expected +++ b/glib/tests/markups/fail-28.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 1: Entity name 'am|' is not known +ERROR Error on line 1: Entity name “am|” is not known diff --git a/glib/tests/markups/fail-29.expected b/glib/tests/markups/fail-29.expected index ddc0090cc..d41596143 100644 --- a/glib/tests/markups/fail-29.expected +++ b/glib/tests/markups/fail-29.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 1: Entity name 'bar' is not known +ERROR Error on line 1: Entity name “bar” is not known diff --git a/glib/tests/markups/fail-3.expected b/glib/tests/markups/fail-3.expected index e39f81c9a..dcb2a02a4 100644 --- a/glib/tests/markups/fail-3.expected +++ b/glib/tests/markups/fail-3.expected @@ -1,5 +1,5 @@ ELEMENT 'foobar' -ERROR Error on line 49 char 2: Invalid UTF-8 encoded text in name - not valid ' +ERROR Error on line 49 char 2: Invalid UTF-8 encoded text in name — not valid “ Παν語 This is a list of ways to say hello in various languages. Its purpose is to illustrate a number of scripts. @@ -47,4 +47,4 @@ Difference among chinese characters in GB, JIS, KSC, BIG5:‎ BIG5 -- 元氣 開發 -' +” diff --git a/glib/tests/markups/fail-30.expected b/glib/tests/markups/fail-30.expected index 15169e35f..fc8c6eb74 100644 --- a/glib/tests/markups/fail-30.expected +++ b/glib/tests/markups/fail-30.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 1: Entity did not end with a semicolon; most likely you used an ampersand character without intending to start an entity - escape ampersand as & +ERROR Error on line 1: Entity did not end with a semicolon; most likely you used an ampersand character without intending to start an entity — escape ampersand as & diff --git a/glib/tests/markups/fail-31.expected b/glib/tests/markups/fail-31.expected index a17ae976c..67c0190d5 100644 --- a/glib/tests/markups/fail-31.expected +++ b/glib/tests/markups/fail-31.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 1: Failed to parse '34592348345343453453455645765736575865767', which should have been a digit inside a character reference (ê for example) - perhaps the digit is too large +ERROR Error on line 1: Failed to parse “34592348345343453453455645765736575865767”, which should have been a digit inside a character reference (ê for example) — perhaps the digit is too large diff --git a/glib/tests/markups/fail-32.expected b/glib/tests/markups/fail-32.expected index c3d9c45af..564dd41d5 100644 --- a/glib/tests/markups/fail-32.expected +++ b/glib/tests/markups/fail-32.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 1: Character reference '0' does not encode a permitted character +ERROR Error on line 1: Character reference “0” does not encode a permitted character diff --git a/glib/tests/markups/fail-33.expected b/glib/tests/markups/fail-33.expected index c4854633c..e84ed71d1 100644 --- a/glib/tests/markups/fail-33.expected +++ b/glib/tests/markups/fail-33.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 1: Failed to parse '', which should have been a digit inside a character reference (ê for example) - perhaps the digit is too large +ERROR Error on line 1: Failed to parse “”, which should have been a digit inside a character reference (ê for example) — perhaps the digit is too large diff --git a/glib/tests/markups/fail-34.expected b/glib/tests/markups/fail-34.expected index 7fac38c00..4cb1363c8 100644 --- a/glib/tests/markups/fail-34.expected +++ b/glib/tests/markups/fail-34.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 1: Character reference did not end with a semicolon; most likely you used an ampersand character without intending to start an entity - escape ampersand as & +ERROR Error on line 1: Character reference did not end with a semicolon; most likely you used an ampersand character without intending to start an entity — escape ampersand as & diff --git a/glib/tests/markups/fail-35.expected b/glib/tests/markups/fail-35.expected index 15169e35f..fc8c6eb74 100644 --- a/glib/tests/markups/fail-35.expected +++ b/glib/tests/markups/fail-35.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 1: Entity did not end with a semicolon; most likely you used an ampersand character without intending to start an entity - escape ampersand as & +ERROR Error on line 1: Entity did not end with a semicolon; most likely you used an ampersand character without intending to start an entity — escape ampersand as & diff --git a/glib/tests/markups/fail-36.expected b/glib/tests/markups/fail-36.expected index 2bd9fbb7f..3f806dcf3 100644 --- a/glib/tests/markups/fail-36.expected +++ b/glib/tests/markups/fail-36.expected @@ -1,4 +1,4 @@ ELEMENT 'foo' TEXT '�' END 'foo' -ERROR Error on line 2 char 1: '^$non-carriage-null-fail|' is not a valid name +ERROR Error on line 2 char 1: “^$non-carriage-null-fail|” is not a valid name diff --git a/glib/tests/markups/fail-37.expected b/glib/tests/markups/fail-37.expected index f04ec3556..edc683ecc 100644 --- a/glib/tests/markups/fail-37.expected +++ b/glib/tests/markups/fail-37.expected @@ -1 +1 @@ -ERROR Error on line 1 char 2: ' ' is not a valid character following a '<' character; it may not begin an element name +ERROR Error on line 1 char 2: “ ” is not a valid character following a “<” character; it may not begin an element name diff --git a/glib/tests/markups/fail-38.expected b/glib/tests/markups/fail-38.expected index f25b4cdd2..3a5f86509 100644 --- a/glib/tests/markups/fail-38.expected +++ b/glib/tests/markups/fail-38.expected @@ -1,3 +1,3 @@ ELEMENT 'foo' TEXT 'data' -ERROR Error on line 1 char 11: ' ' is not a valid character following a '<' character; it may not begin an element name +ERROR Error on line 1 char 11: “ ” is not a valid character following a “<” character; it may not begin an element name diff --git a/glib/tests/markups/fail-39.expected b/glib/tests/markups/fail-39.expected index de0e4b8db..1b5d234a3 100644 --- a/glib/tests/markups/fail-39.expected +++ b/glib/tests/markups/fail-39.expected @@ -1,3 +1,3 @@ ELEMENT 'foo' TEXT 'data' -ERROR Error on line 1 char 12: ' ' is not a valid character following the characters '' character to end the empty-element tag 'foo' +ERROR Error on line 1 char 6: Odd character “≻”, expected a “>” character to end the empty-element tag “foo” diff --git a/glib/tests/markups/fail-45.expected b/glib/tests/markups/fail-45.expected index 866b75133..1899cdf5d 100644 --- a/glib/tests/markups/fail-45.expected +++ b/glib/tests/markups/fail-45.expected @@ -1,3 +1,3 @@ ELEMENT 'foo' TEXT '' -ERROR Error on line 1 char 12: '≻' is not a valid character following the close element name 'foo'; the allowed character is '>' +ERROR Error on line 1 char 12: “≻” is not a valid character following the close element name “foo”; the allowed character is “>” diff --git a/glib/tests/markups/fail-46.expected b/glib/tests/markups/fail-46.expected index f3ab8ca90..7124919a2 100644 --- a/glib/tests/markups/fail-46.expected +++ b/glib/tests/markups/fail-46.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 3 char 2: Document ended unexpectedly with elements still open - 'foo' was the last element opened +ERROR Error on line 3 char 2: Document ended unexpectedly with elements still open — “foo” was the last element opened diff --git a/glib/tests/markups/fail-47.expected b/glib/tests/markups/fail-47.expected index 89dc4b400..1083489f8 100644 --- a/glib/tests/markups/fail-47.expected +++ b/glib/tests/markups/fail-47.expected @@ -1 +1 @@ -ERROR Error on line 1: Failed to parse '', which should have been a digit inside a character reference (ê for example) - perhaps the digit is too large +ERROR Error on line 1: Failed to parse “”, which should have been a digit inside a character reference (ê for example) — perhaps the digit is too large diff --git a/glib/tests/markups/fail-48.expected b/glib/tests/markups/fail-48.expected index e5fa74004..ed546bf70 100644 --- a/glib/tests/markups/fail-48.expected +++ b/glib/tests/markups/fail-48.expected @@ -1 +1 @@ -ERROR Error on line 2 char 2: Odd character '>', expected a '=' after attribute name 'bar' of element 'fail' +ERROR Error on line 2 char 2: Odd character “>”, expected a “=” after attribute name “bar” of element “fail” diff --git a/glib/tests/markups/fail-49.expected b/glib/tests/markups/fail-49.expected index fc3bacb57..386e1a415 100644 --- a/glib/tests/markups/fail-49.expected +++ b/glib/tests/markups/fail-49.expected @@ -1,3 +1,3 @@ ELEMENT 'foo' TEXT '' -ERROR Error on line 2 char 2: Document ended unexpectedly inside the close tag for element 'foo' +ERROR Error on line 2 char 2: Document ended unexpectedly inside the close tag for element “foo” diff --git a/glib/tests/markups/fail-5.expected b/glib/tests/markups/fail-5.expected index e519015d5..0105827f0 100644 --- a/glib/tests/markups/fail-5.expected +++ b/glib/tests/markups/fail-5.expected @@ -1 +1 @@ -ERROR Error on line 2 char 1: '|foo' is not a valid name +ERROR Error on line 2 char 1: “|foo” is not a valid name diff --git a/glib/tests/markups/fail-6.expected b/glib/tests/markups/fail-6.expected index b72246888..d41f00e74 100644 --- a/glib/tests/markups/fail-6.expected +++ b/glib/tests/markups/fail-6.expected @@ -1 +1 @@ -ERROR Error on line 2 char 1: 'foo|' is not a valid name: '|' +ERROR Error on line 2 char 1: “foo|” is not a valid name: “|” diff --git a/glib/tests/markups/fail-7.expected b/glib/tests/markups/fail-7.expected index 40b61c152..a2843cd72 100644 --- a/glib/tests/markups/fail-7.expected +++ b/glib/tests/markups/fail-7.expected @@ -1 +1 @@ -ERROR Error on line 1 char 15: 'bar}"baz"' is not a valid name: '}' +ERROR Error on line 1 char 15: “bar}"baz"” is not a valid name: “}” diff --git a/glib/tests/markups/fail-8.expected b/glib/tests/markups/fail-8.expected index 31651aa6b..121163d8e 100644 --- a/glib/tests/markups/fail-8.expected +++ b/glib/tests/markups/fail-8.expected @@ -1,2 +1,2 @@ ELEMENT 'foo' -ERROR Error on line 1 char 6: Odd character '}', expected a '>' character to end the empty-element tag 'foo' +ERROR Error on line 1 char 6: Odd character “}”, expected a “>” character to end the empty-element tag “foo” diff --git a/glib/tests/markups/fail-9.expected b/glib/tests/markups/fail-9.expected index 9994eb345..f2d77cca6 100644 --- a/glib/tests/markups/fail-9.expected +++ b/glib/tests/markups/fail-9.expected @@ -1 +1 @@ -ERROR Error on line 1 char 10: Odd character '{', expected an open quote mark after the equals sign when giving value for attribute 'bar' of element 'foo' +ERROR Error on line 1 char 10: Odd character “{”, expected an open quote mark after the equals sign when giving value for attribute “bar” of element “foo” From b974cccdafc97397a7c74d4b9a4049bfe7668e35 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Piotr=20Dr=C4=85g?= Date: Fri, 8 Jun 2018 16:15:54 +0200 Subject: [PATCH 2/2] Revert "Partially revert 10c490cdfe3ae042f747bd00f787492e2bdb7ed0" This reverts commit 2d56c49b1085ae3ad769e6b59329cf493eb0f8a1. --- gio/gdbusconnection.c | 30 ++++++++-------- gio/glib-compile-schemas.c | 16 ++++----- glib/gmarkup.c | 70 +++++++++++++++++++------------------- 3 files changed, 58 insertions(+), 58 deletions(-) diff --git a/gio/gdbusconnection.c b/gio/gdbusconnection.c index ae463e430..09b782e46 100644 --- a/gio/gdbusconnection.c +++ b/gio/gdbusconnection.c @@ -4121,7 +4121,7 @@ invoke_get_property_in_idle_cb (gpointer _data) { reply = g_dbus_message_new_method_error (data->message, "org.freedesktop.DBus.Error.UnknownMethod", - _("No such interface 'org.freedesktop.DBus.Properties' on object at path %s"), + _("No such interface “org.freedesktop.DBus.Properties” on object at path %s"), g_dbus_message_get_path (data->message)); g_dbus_connection_send_message (data->connection, reply, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL); g_object_unref (reply); @@ -4263,7 +4263,7 @@ validate_and_maybe_schedule_property_getset (GDBusConnection *connect { reply = g_dbus_message_new_method_error (message, "org.freedesktop.DBus.Error.InvalidArgs", - _("No such property '%s'"), + _("No such property “%s”"), property_name); g_dbus_connection_send_message_unlocked (connection, reply, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL); g_object_unref (reply); @@ -4275,7 +4275,7 @@ validate_and_maybe_schedule_property_getset (GDBusConnection *connect { reply = g_dbus_message_new_method_error (message, "org.freedesktop.DBus.Error.InvalidArgs", - _("Property '%s' is not readable"), + _("Property “%s” is not readable"), property_name); g_dbus_connection_send_message_unlocked (connection, reply, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL); g_object_unref (reply); @@ -4286,7 +4286,7 @@ validate_and_maybe_schedule_property_getset (GDBusConnection *connect { reply = g_dbus_message_new_method_error (message, "org.freedesktop.DBus.Error.InvalidArgs", - _("Property '%s' is not writable"), + _("Property “%s” is not writable"), property_name); g_dbus_connection_send_message_unlocked (connection, reply, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL); g_object_unref (reply); @@ -4306,7 +4306,7 @@ validate_and_maybe_schedule_property_getset (GDBusConnection *connect { reply = g_dbus_message_new_method_error (message, "org.freedesktop.DBus.Error.InvalidArgs", - _("Error setting property '%s': Expected type '%s' but got '%s'"), + _("Error setting property “%s”: Expected type “%s” but got “%s”"), property_name, property_info->signature, g_variant_get_type_string (value)); g_dbus_connection_send_message_unlocked (connection, reply, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL); @@ -4411,7 +4411,7 @@ handle_getset_property (GDBusConnection *connection, GDBusMessage *reply; reply = g_dbus_message_new_method_error (message, "org.freedesktop.DBus.Error.InvalidArgs", - _("No such interface '%s'"), + _("No such interface “%s”"), interface_name); g_dbus_connection_send_message_unlocked (eo->connection, reply, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL); g_object_unref (reply); @@ -4468,7 +4468,7 @@ invoke_get_all_properties_in_idle_cb (gpointer _data) { reply = g_dbus_message_new_method_error (data->message, "org.freedesktop.DBus.Error.UnknownMethod", - _("No such interface 'org.freedesktop.DBus.Properties' on object at path %s"), + _("No such interface “org.freedesktop.DBus.Properties” on object at path %s"), g_dbus_message_get_path (data->message)); g_dbus_connection_send_message (data->connection, reply, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL); g_object_unref (reply); @@ -4837,7 +4837,7 @@ call_in_idle_cb (gpointer user_data) GDBusMessage *reply; reply = g_dbus_message_new_method_error (g_dbus_method_invocation_get_message (invocation), "org.freedesktop.DBus.Error.UnknownMethod", - _("No such interface '%s' on object at path %s"), + _("No such interface “%s” on object at path %s"), g_dbus_method_invocation_get_interface_name (invocation), g_dbus_method_invocation_get_object_path (invocation)); g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), reply, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL); @@ -4935,7 +4935,7 @@ validate_and_maybe_schedule_method_call (GDBusConnection *connection, { reply = g_dbus_message_new_method_error (message, "org.freedesktop.DBus.Error.UnknownMethod", - _("No such method '%s'"), + _("No such method “%s”"), g_dbus_message_get_member (message)); g_dbus_connection_send_message_unlocked (connection, reply, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL); g_object_unref (reply); @@ -4966,7 +4966,7 @@ validate_and_maybe_schedule_method_call (GDBusConnection *connection, reply = g_dbus_message_new_method_error (message, "org.freedesktop.DBus.Error.InvalidArgs", - _("Type of message, '%s', does not match expected type '%s'"), + _("Type of message, “%s”, does not match expected type “%s”"), g_variant_get_type_string (parameters), type_string); g_dbus_connection_send_message_unlocked (connection, reply, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL); @@ -5624,7 +5624,7 @@ decode_method_reply (GDBusMessage *reply, g_set_error (error, G_IO_ERROR, G_IO_ERROR_INVALID_ARGUMENT, - _("Method '%s' returned type '%s', but expected '%s'"), + _("Method “%s” returned type “%s”, but expected “%s”"), method_name, g_variant_get_type_string (result), type_string); g_variant_unref (result); @@ -6588,7 +6588,7 @@ handle_subtree_method_invocation (GDBusConnection *connection, GDBusMessage *reply; reply = g_dbus_message_new_method_error (message, "org.freedesktop.DBus.Error.InvalidArgs", - _("No such interface '%s'"), + _("No such interface “%s”"), interface_name); g_dbus_connection_send_message (es->connection, reply, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL); g_object_unref (reply); @@ -6699,7 +6699,7 @@ process_subtree_vtable_message_in_idle_cb (gpointer _data) GDBusMessage *reply; reply = g_dbus_message_new_method_error (data->message, "org.freedesktop.DBus.Error.UnknownMethod", - _("Method '%s' on interface '%s' with signature '%s' does not exist"), + _("Method “%s” on interface “%s” with signature “%s” does not exist"), g_dbus_message_get_member (data->message), g_dbus_message_get_interface (data->message), g_dbus_message_get_signature (data->message)); @@ -7097,7 +7097,7 @@ distribute_method_call (GDBusConnection *connection, /* if we end up here, the message has not been not handled - so return an error saying this */ reply = g_dbus_message_new_method_error (message, "org.freedesktop.DBus.Error.UnknownMethod", - _("No such interface '%s' on object at path %s"), + _("No such interface “%s” on object at path %s"), interface_name, object_path); g_dbus_connection_send_message_unlocked (connection, reply, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL); @@ -7149,7 +7149,7 @@ message_bus_get_singleton (GBusType bus_type, G_IO_ERROR, G_IO_ERROR_INVALID_ARGUMENT, _("Cannot determine bus address from DBUS_STARTER_BUS_TYPE environment variable" - " - unknown value '%s'"), + " — unknown value “%s”"), starter_bus); } else diff --git a/gio/glib-compile-schemas.c b/gio/glib-compile-schemas.c index f6e1b4036..6794ca910 100644 --- a/gio/glib-compile-schemas.c +++ b/gio/glib-compile-schemas.c @@ -1931,8 +1931,8 @@ set_overrides (GHashTable *schema_table, if (state == NULL) { - fprintf (stderr, _("No such key '%s' in schema '%s' as " - "specified in override file '%s'"), + fprintf (stderr, _("No such key “%s” in schema “%s” as " + "specified in override file “%s”"), key, group, filename); if (!strict) @@ -1957,8 +1957,8 @@ set_overrides (GHashTable *schema_table, if (value == NULL) { - fprintf (stderr, _("error parsing key '%s' in schema '%s' " - "as specified in override file '%s': " + fprintf (stderr, _("error parsing key “%s” in schema “%s” " + "as specified in override file “%s”: " "%s."), key, group, filename, error->message); @@ -1985,8 +1985,8 @@ set_overrides (GHashTable *schema_table, g_variant_compare (value, state->maximum) > 0) { fprintf (stderr, - _("override for key '%s' in schema '%s' in " - "override file '%s' is outside the range " + _("override for key “%s” in schema “%s” in " + "override file “%s” is outside the range " "given in the schema"), key, group, filename); @@ -2013,8 +2013,8 @@ set_overrides (GHashTable *schema_table, if (!is_valid_choices (value, state->strinfo)) { fprintf (stderr, - _("override for key '%s' in schema '%s' in " - "override file '%s' is not in the list " + _("override for key “%s” in schema “%s” in " + "override file “%s” is not in the list " "of valid choices"), key, group, filename); diff --git a/glib/gmarkup.c b/glib/gmarkup.c index ed30ed297..372b3a9b2 100644 --- a/glib/gmarkup.c +++ b/glib/gmarkup.c @@ -458,7 +458,7 @@ slow_name_validate (GMarkupParseContext *context, if (!g_utf8_validate (name, strlen (name), NULL)) { set_error (context, error, G_MARKUP_ERROR_BAD_UTF8, - _("Invalid UTF-8 encoded text in name - not valid '%s'"), name); + _("Invalid UTF-8 encoded text in name — not valid “%s”"), name); return FALSE; } @@ -469,7 +469,7 @@ slow_name_validate (GMarkupParseContext *context, g_unichar_isalpha (g_utf8_get_char (p)))))) { set_error (context, error, G_MARKUP_ERROR_PARSE, - _("'%s' is not a valid name"), name); + _("“%s” is not a valid name"), name); return FALSE; } @@ -485,7 +485,7 @@ slow_name_validate (GMarkupParseContext *context, g_unichar_isalpha (g_utf8_get_char (p)))))) { set_error (context, error, G_MARKUP_ERROR_PARSE, - _("'%s' is not a valid name: '%c'"), name, *p); + _("“%s” is not a valid name: “%c”"), name, *p); return FALSE; } } @@ -541,7 +541,7 @@ text_validate (GMarkupParseContext *context, if (!g_utf8_validate (p, len, NULL)) { set_error (context, error, G_MARKUP_ERROR_BAD_UTF8, - _("Invalid UTF-8 encoded text in name - not valid '%s'"), p); + _("Invalid UTF-8 encoded text in name — not valid “%s”"), p); return FALSE; } else @@ -672,10 +672,10 @@ unescape_gstring_inplace (GMarkupParseContext *context, { set_unescape_error (context, error, from, G_MARKUP_ERROR_PARSE, - _("Failed to parse '%-.*s', which " + _("Failed to parse “%-.*s”, which " "should have been a digit " "inside a character reference " - "(ê for example) - perhaps " + "(ê for example) — perhaps " "the digit is too large"), (int)(end - from), from); return FALSE; @@ -688,7 +688,7 @@ unescape_gstring_inplace (GMarkupParseContext *context, "semicolon; " "most likely you used an ampersand " "character without intending to start " - "an entity - escape ampersand as &")); + "an entity — escape ampersand as &")); return FALSE; } else @@ -710,7 +710,7 @@ unescape_gstring_inplace (GMarkupParseContext *context, { set_unescape_error (context, error, from, G_MARKUP_ERROR_PARSE, - _("Character reference '%-.*s' does not " + _("Character reference “%-.*s” does not " "encode a permitted character"), (int)(end - from), from); return FALSE; @@ -748,7 +748,7 @@ unescape_gstring_inplace (GMarkupParseContext *context, if (*from == ';') set_unescape_error (context, error, from, G_MARKUP_ERROR_PARSE, - _("Empty entity '&;' seen; valid " + _("Empty entity “&;” seen; valid " "entities are: & " < > '")); else { @@ -756,7 +756,7 @@ unescape_gstring_inplace (GMarkupParseContext *context, if (end) set_unescape_error (context, error, from, G_MARKUP_ERROR_PARSE, - _("Entity name '%-.*s' is not known"), + _("Entity name “%-.*s” is not known"), (int)(end - from), from); else set_unescape_error (context, error, @@ -764,7 +764,7 @@ unescape_gstring_inplace (GMarkupParseContext *context, _("Entity did not end with a semicolon; " "most likely you used an ampersand " "character without intending to start " - "an entity - escape ampersand as &")); + "an entity — escape ampersand as &")); } return FALSE; } @@ -1207,8 +1207,8 @@ g_markup_parse_context_parse (GMarkupParseContext *context, set_error (context, error, G_MARKUP_ERROR_PARSE, - _("'%s' is not a valid character following " - "a '<' character; it may not begin an " + _("“%s” is not a valid character following " + "a “<” character; it may not begin an " "element name"), utf8_str (context->iter, buf)); } @@ -1249,8 +1249,8 @@ g_markup_parse_context_parse (GMarkupParseContext *context, set_error (context, error, G_MARKUP_ERROR_PARSE, - _("Odd character '%s', expected a '>' character " - "to end the empty-element tag '%s'"), + _("Odd character “%s”, expected a “>” character " + "to end the empty-element tag “%s”"), utf8_str (context->iter, buf), current_element (context)); } @@ -1330,8 +1330,8 @@ g_markup_parse_context_parse (GMarkupParseContext *context, set_error (context, error, G_MARKUP_ERROR_PARSE, - _("Odd character '%s', expected a '=' after " - "attribute name '%s' of element '%s'"), + _("Odd character “%s”, expected a “=” after " + "attribute name “%s” of element “%s”"), utf8_str (context->iter, buf), current_attribute (context), current_element (context)); @@ -1371,9 +1371,9 @@ g_markup_parse_context_parse (GMarkupParseContext *context, set_error (context, error, G_MARKUP_ERROR_PARSE, - _("Odd character '%s', expected a '>' or '/' " + _("Odd character “%s”, expected a “>” or “/” " "character to end the start tag of " - "element '%s', or optionally an attribute; " + "element “%s”, or optionally an attribute; " "perhaps you used an invalid character in " "an attribute name"), utf8_str (context->iter, buf), @@ -1415,9 +1415,9 @@ g_markup_parse_context_parse (GMarkupParseContext *context, set_error (context, error, G_MARKUP_ERROR_PARSE, - _("Odd character '%s', expected an open quote mark " + _("Odd character “%s”, expected an open quote mark " "after the equals sign when giving value for " - "attribute '%s' of element '%s'"), + "attribute “%s” of element “%s”"), utf8_str (context->iter, buf), current_attribute (context), current_element (context)); @@ -1548,8 +1548,8 @@ g_markup_parse_context_parse (GMarkupParseContext *context, set_error (context, error, G_MARKUP_ERROR_PARSE, - _("'%s' is not a valid character following " - "the characters 'iter, buf), utf8_str (context->iter, buf)); @@ -1584,9 +1584,9 @@ g_markup_parse_context_parse (GMarkupParseContext *context, set_error (context, error, G_MARKUP_ERROR_PARSE, - _("'%s' is not a valid character following " - "the close element name '%s'; the allowed " - "character is '>'"), + _("“%s” is not a valid character following " + "the close element name “%s”; the allowed " + "character is “>”"), utf8_str (context->iter, buf), close_name->str); } @@ -1595,7 +1595,7 @@ g_markup_parse_context_parse (GMarkupParseContext *context, set_error (context, error, G_MARKUP_ERROR_PARSE, - _("Element '%s' was closed, no element " + _("Element “%s” was closed, no element " "is currently open"), close_name->str); } @@ -1604,8 +1604,8 @@ g_markup_parse_context_parse (GMarkupParseContext *context, set_error (context, error, G_MARKUP_ERROR_PARSE, - _("Element '%s' was closed, but the currently " - "open element is '%s'"), + _("Element “%s” was closed, but the currently " + "open element is “%s”"), close_name->str, current_element (context)); } @@ -1771,7 +1771,7 @@ g_markup_parse_context_end_parse (GMarkupParseContext *context, case STATE_AFTER_OPEN_ANGLE: set_error_literal (context, error, G_MARKUP_ERROR_PARSE, - _("Document ended unexpectedly just after an open angle bracket '<'")); + _("Document ended unexpectedly just after an open angle bracket “<”")); break; case STATE_AFTER_CLOSE_ANGLE: @@ -1779,8 +1779,8 @@ g_markup_parse_context_end_parse (GMarkupParseContext *context, { /* Error message the same as for INSIDE_TEXT */ set_error (context, error, G_MARKUP_ERROR_PARSE, - _("Document ended unexpectedly with elements still open - " - "'%s' was the last element opened"), + _("Document ended unexpectedly with elements still open — " + "“%s” was the last element opened"), current_element (context)); } break; @@ -1824,8 +1824,8 @@ g_markup_parse_context_end_parse (GMarkupParseContext *context, case STATE_INSIDE_TEXT: g_assert (context->tag_stack != NULL); set_error (context, error, G_MARKUP_ERROR_PARSE, - _("Document ended unexpectedly with elements still open - " - "'%s' was the last element opened"), + _("Document ended unexpectedly with elements still open — " + "“%s” was the last element opened"), current_element (context)); break; @@ -1834,7 +1834,7 @@ g_markup_parse_context_end_parse (GMarkupParseContext *context, case STATE_AFTER_CLOSE_TAG_NAME: set_error (context, error, G_MARKUP_ERROR_PARSE, _("Document ended unexpectedly inside the close tag for " - "element '%s'"), current_element (context)); + "element “%s”"), current_element (context)); break; case STATE_INSIDE_PASSTHROUGH: