Closed Bug 1190593 Opened 9 years ago Closed 9 years ago

Rename qps-plocm to ar-x-psbidi, qps-ploc to fr-x-psaccent

Categories

(Firefox OS Graveyard :: Gaia::L10n, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: zbraniecki, Assigned: stas)

References

Details

Attachments

(1 file)

(deleted), text/x-github-pull-request
zbraniecki
: review+
Details
Mirrored pseudolocale (qps-plocm) is used for testing RTL. With a switch to Intl, we loose ability to pseudolocalize that, and Intl will pick en-US when it fails to recognize the language tag. The solution would be to inject 'ar' as a fallback for qps-plocm, so that Intl picks it. This way date/time in qps-plocm would be from 'ar' which better represents the actual scenario.
This may require us to switch Intl languages source from navigator.languages to document.l10n.languages
Thoughts?
Flags: needinfo?(stas)
If we need to change Intl anyways, maybe we should standardize qps-ploc and qps-plocm? Microsoft already usese these tags too, so there's some industry precedent. Ideally, Intl would know that qps-plocm is RTL and it could also know how to format things in it.
Flags: needinfo?(stas)
That would require extension to CLDR? Initially, I'd say that maybe if we centralizie Intl calls via a helper in bug 1191011, then we can alter the navigator.languages there? Or we could go for document.l10n.languages from l20n.js for Intl formatters and set 'ar' there as a second for qps-plocm. I'd still be interested in standardizing them, so I'm adding it to my bucket list of Intl API updates :)
Attached file Pull request (deleted) —
This PR renames qps-ploc and qps-plocm to en-x-psaccent and ar-x-psbidib respectively, following Google's propsal at http://unicode.org/cldr/trac/ticket/3971.
Assignee: nobody → stas
Status: NEW → ASSIGNED
Attachment #8677745 - Flags: review?(gandalf)
Attachment #8677745 - Flags: review?(gandalf) → review+
Summary: Use 'ar' as a fallback language for qps-plocm → Rename qps-plocm to ar-x-psbidi, qps-ploc to en-x-psaccent
Pike, flod -- I'm following Google here and I'd like to rename our pseudolocales to en-x-psaccent and ar-x-psbidi. The advantage is that we can then easily plug these codes into Intl and get something LTR or RTL, without any tweaking nor instrumentation. See http://unicode.org/cldr/trac/ticket/3971. What do you think about this change? Bug 1217733 has the Gaia part of the change.
Flags: needinfo?(l10n)
Flags: needinfo?(francesco.lodolo)
What about "using Intl" means that we can't use qps? Generally, a ticket with no action for 4 years (basically) isn't a compelling lead to follow.
Flags: needinfo?(l10n)
(In reply to Axel Hecht [:Pike] from comment #7) > What about "using Intl" means that we can't use qps? new Intl.DateTimeFormat(['qps-plocm']) means nothing to Intl, and it has no idea which language rules it should use. new Intl.DateTimeFormat(['ar-x-psbidi']) resolves to 'ar' meaning Intl can then use Arabic rules for displaying date and time. This is desirable for RTL testing since it's much closer to reality and shimming it with English rules is close to impossible.
I don't really have a strong opinion about this, even if I can see the benefit in using the new codes (no need to tweak them before passing to intl if it falls back correctly to Arabic and English). What was the reasoning behind the choice of current codes?
Flags: needinfo?(francesco.lodolo)
In the same spirit, I suggest we rename qps-ploc (Accented English) to fr-x-psaccent.
Summary: Rename qps-plocm to ar-x-psbidi, qps-ploc to en-x-psaccent → Rename qps-plocm to ar-x-psbidi, qps-ploc to fr-x-psaccent
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Blocks: 1217733
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: