GNOME Bugzilla – Bug 705518
lib: Better name/description for street numbers
Last modified: 2013-08-07 10:10:50 UTC
See patch
Created attachment 250883 [details] [review] lib: Better name/description for street numbers Currently we'd just show the house number in results for street number searches, e.g Search for "Otavantie 2" would result in places named "2". This patch fixes this issue by combining street name and house number. Since format is not the same in all locales, we allow the translators to format the string.
Review of attachment 250883 [details] [review]: ::: geocode-glib/geocode-reverse.c @@ +140,3 @@ + house_number = value; + } else if (house_number != NULL && g_strcmp0 (members[i], "road") == 0) { + /* street + number (e.g Baker Street 221) */ Prefix with "translators comment". House numbers come first in England ;) 221 Baker Street, not Baker Street 221. It's also the case in en_US (our "untranslated" language).
Review of attachment 250883 [details] [review]: ::: geocode-glib/geocode-reverse.c @@ +140,3 @@ + house_number = value; + } else if (house_number != NULL && g_strcmp0 (members[i], "road") == 0) { + /* street + number (e.g Baker Street 221) */ Ah, I thought that is American way. :) Lunch?
Created attachment 250954 [details] [review] lib: Better name/description for street numbers Updated the comment as per review.
Review of attachment 250954 [details] [review]: ::: geocode-glib/geocode-reverse.c @@ +28,3 @@ #include <libsoup/soup.h> +#include <config.h> +#include <glib/gi18n-lib.h> You don't have anything actually initialising the text domain, etc. See: https://git.gnome.org/browse/gnome-desktop/tree/libgnome-desktop/gnome-wall-clock.c#n181
Review of attachment 250954 [details] [review]: ::: geocode-glib/geocode-reverse.c @@ +28,3 @@ #include <libsoup/soup.h> +#include <config.h> +#include <glib/gi18n-lib.h> hmm.. so we do that in all class_init's separately? For now we are only adding translated string in the module but later we're likely to add a few to other modules.
Created attachment 250983 [details] [review] lib: Better name/description for street numbers * Initialize text domain from class_init. * Actually format the address in default locale: house number + street.
Review of attachment 250983 [details] [review]: Looks good.
Attachment 250983 [details] pushed as 0a4b035 - lib: Better name/description for street numbers