Closed
Bug 878599
Opened 12 years ago
Closed 12 years ago
Postal address order for Germany is wrong
Categories
(Thunderbird :: Address Book, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
Thunderbird 25.0
People
(Reporter: z0idberg, Assigned: aceman)
Details
(Keywords: polish)
Attachments
(1 file, 1 obsolete file)
3.03 KB,
patch
|
iannbugzilla
:
review+
mconley
:
review+
|
Details | Diff | Splinter Review |
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:21.0) Gecko/20100101 Firefox/21.0 (Beta/Release)
Build ID: 20130511120803
Steps to reproduce:
The current postal address order is not correct for Germany.
The order for Germany should be:
Street
PostalCode City
Instead, it is displayed as:
Street
City, PostalCode
This issue is also present (and even graver) for other countries. Please support this. The correct order can be ascertained when looking at the country field.
To give a real life example:
The headquarter of Microsoft Germany is located in:
Konrad-Zuse-Straße 1
85716 Unterschleißheim
If you mean the contact preview in the addressbook, then this is true for more countries.
Assuming mconley's new addressbook will not land in TB24 this still could if done quickly.
http://hg.mozilla.org/comm-central/file/385e5d45032a/mail/components/addrbook/content/abCardViewOverlay.js#l465
The print preview of the addressbook uses a second format (City ZIP), with no comma.
But to be completely correct internationally, you would also need the Country code in the address:
Konrad-Zuse-Straße 1
DE-85716 Unterschleißheim
So this seems to do it. It even seems the necessary strings are already there, just unused.
I just want to note, that technically, the format of the address should probably depend on the addressee country, not on your local country. But if most of the addressees are local to the country of the TB user, things could be better with this patch.
Attachment #757536 -
Flags: ui-review?(bwinton)
Attachment #757536 -
Flags: review?(mconley)
Comment on attachment 757536 [details] [diff] [review]
patch
The strings are currently used in nsAbCardProperty.cpp (e.g. http://mxr.mozilla.org/comm-central/source/mailnews/addrbook/src/nsAbCardProperty.cpp#1051)
The logic appears to be the same.
It would be good if the same changes could be made to suite's version of the file at the same time.
Comment 4•12 years ago
|
||
Comment on attachment 757536 [details] [diff] [review]
patch
ui-r=me, based on inspection and comments in the bug.
(Well, those, and the fact that "string += other string" is usually the wrong thing to do. ;)
Thanks,
Blake.
Attachment #757536 -
Flags: ui-review?(bwinton) → ui-review+
Oh, great for quick support! Thanks.
I guess for a thorough support some kind of small database/list with patterns for every country would be necessary.
For example like this:
Germany: {Street}\n{Post Code} {City}\n{Country}
Austria: {Street}\n{Post Code} {City}\n{Country}
France: {Street}\n{Post Code} {City}\n{Country}
UK: {Street}\n{City}\n{Post Code}\n{Country}
USA: {Stret}\n{City}, {State} {Post Code}\n{Country}
Japan (Japanese Characters): 〒{Post Code}\n{State}{City}{Street}\n{Country}
Japan (Romanized): {Stret}\n{City}, {State} {Post Code}\n{Country}
A list can be found in this Wikipedia article:
http://en.wikipedia.org/wiki/Address_%28geography%29#Mailing_address_format_by_country
The problem is that the pattern should be determined by the recipients’ country. But because the country is saved in a localized name (e.g. Germany would be “Deutschland”), it might be hard for Thunderbird to see this.
Also, especially for country with non-latin scripts: Two kinds of systems can be in use: the original system and a transcription based system (see the Japanese example above).
(In reply to Ian Neal from comment #3)
> The strings are currently used in nsAbCardProperty.cpp (e.g.
> http://mxr.mozilla.org/comm-central/source/mailnews/addrbook/src/
> nsAbCardProperty.cpp#1051)
> The logic appears to be the same.
> It would be good if the same changes could be made to suite's version of the
> file at the same time.
Yes, that is where I copied the logic from. I don't know why the logic needs to be duplicated like this. But maybe it all goes away with the new AB.
(In reply to z0idberg from comment #5)
> I guess for a thorough support some kind of small database/list with
> patterns for every country would be necessary.
Exactly. And I am not sure we want to delve into that in TB. Probably the most universal way would be to show the address split into the individual fields:
Street:
Street number:
City:
ZIP:
Country:
It will be verbose but universal without the need to handle all the specific formatting. Or is somebody using TB to print addresses directly onto postal envelopes?
(In reply to :aceman from comment #6)
> Exactly. And I am not sure we want to delve into that in TB. Probably the
> most universal way would be to show the address split into the individual
> fields:
> It will be verbose but universal without the need to handle all the specific
> formatting. Or is somebody using TB to print addresses directly onto postal
> envelopes?
Well, who knows? Especially if you have foreign contacts and forget how the order is.
I am not sure, but is there such a problem with this kind of list? The list could be done by someone without any programming knowledge (=me) and would only consist of sequences of placeholders and things like \n or colons.
But I guess the problem in itself is that people expect the adress to be displayed in a formatted way. If we have a hard-coded pattern like now, the address looks weird for people like me (in Germany), or becomes next to unusable e.g. in Japan.
Of course, Thunderbird is primarily a Mail application, but it still has an address book. With Lightning installed, it can serve as a basic PIM (It may not be as good as Outlook, but for most people it will be sufficient). Especially if you have people in mind who do not have anything to do with other countries, it would be really nice if the address would be displayed in a correct way.
I don’t know about the new address book and how it will look like, but the current address formatting is plainly US-centric and not suitable for most people, and some kind of split display like you propose is quite inconvenient (in my opinion).
The patch I attached changes from the US centric format to a format that depends on the localizer of TB using existing infrastructure. So for German TB, all the addresses will display in the German format. Which will break if you have contacts outside Germany. But it should be better as in the current state it breaks for almost all contacts (except US ones).
What you describe is possible to do, but please file it as a new bug as it needs more infrastructure (e.g. a field for the recipient's country as a country code, not free form as today).
Status: NEW → ASSIGNED
![]() |
Assignee | |
Comment 10•12 years ago
|
||
OK, with Seamonkey version.
Attachment #757536 -
Attachment is obsolete: true
Attachment #757536 -
Flags: review?(mconley)
Attachment #758012 -
Flags: review?(mconley)
Attachment #758012 -
Flags: review?(iann_bugzilla)
Comment 11•12 years ago
|
||
Comment on attachment 758012 [details] [diff] [review]
patch v2
Looks good to me, r=me
Attachment #758012 -
Flags: review?(iann_bugzilla) → review+
Comment 12•12 years ago
|
||
(In reply to :aceman from comment #6)
> (In reply to z0idberg from comment #5)
> > I guess for a thorough support some kind of small database/list with
> > patterns for every country would be necessary.
>
> Exactly. And I am not sure we want to delve into that in TB. Probably the
> most universal way would be to show the address split into the individual
> fields:
This is all covered by an existing bug somewhere.
Comment 13•12 years ago
|
||
Comment on attachment 758012 [details] [diff] [review]
patch v2
Review of attachment 758012 [details] [diff] [review]:
-----------------------------------------------------------------
Looks good! Thanks aceman.
Attachment #758012 -
Flags: review?(mconley) → review+
Keywords: checkin-needed
Comment 14•12 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 25.0
You need to log in
before you can comment on or make changes to this bug.
Description
•