Closed
Bug 1178119
Opened 10 years ago
Closed 10 years ago
Don't force capitalization of localized text in Firefox for iOS
Categories
(Firefox for iOS :: General, defect)
Tracking
()
RESOLVED
FIXED
| Tracking | Status | |
|---|---|---|
| fxios | + | --- |
People
(Reporter: kscanne, Assigned: sleroux)
References
Details
Attachments
(2 files)
Reporting specifically for Irish, but other languages have similar issues; cf bug 830002 and bug 1014639. I'm running version 1.0 (22) of Firefox, on iOS 8.3.
Here's the translation as it appears in Pootle:
http://mozilla.locamotion.org/ga_IE/ios/translate/#unit=13447042
Last week = An tseachtain seo caite
In all caps, this should look like "AN tSEACHTAIN SEO CAITE" (small "t"). See attached screenshot.
Comment 1•10 years ago
|
||
Moving to Firefox OS - General, because there's actually nothing on your side that you can do to fix this.
I think it might be a duplicate of an existing bug about custom/per-locale CSS rules
Assignee: kscanne → nobody
Component: ga-IE / Irish → General
Product: Mozilla Localizations → Firefox OS
QA Contact: bking
Comment 2•10 years ago
|
||
Jet-lagged brain... Firefox for IOS, not Firefox OS.
Product: Firefox OS → Firefox for iOS
Updated•10 years ago
|
Flags: needinfo?(sarentz)
Comment 3•10 years ago
|
||
Could you look into this? It seems to be seriously affected some locales.
Updated•10 years ago
|
tracking-fxios:
--- → ?
Flags: needinfo?(sarentz)
Updated•10 years ago
|
Updated•10 years ago
|
Comment 4•10 years ago
|
||
Update: this is something that's hard to fix without new strings that are naturally in the desired case (which is how it should have been done to start with).
We're past string freeze, so this'll ship for a few weeks in 1.0 and we'll fix it for 1.1.
Sorry for the pain :/
Comment 5•10 years ago
|
||
Tried NSString.uppercaseStringWithLocale() as a quick fix but that has the exact same results as NSString.uppercaseString()
Updated•10 years ago
|
| Assignee | ||
Comment 6•10 years ago
|
||
Stef,
When you added uppercaseStringWithLocale, did you pass in NSLocale.currentLocale into the method?
If that doesn't work, would the solution for this issue be to remove any 'force' capitalization (calls to uppcaseString() we make in our code and rely on the strings provided from localizers for this?
Flags: needinfo?(sarentz)
Comment 7•10 years ago
|
||
Yeah I tried uppercaseStringWithLocale(s, NSLocale.currentLocale()) and that did not give the expected results. Simply the whole string would be uppercased.
I think it would be good if you could take another peek at that quickly. Maybe there is more to it. But if not then yeah lets just ask the localizers to do an uppercase version for those strings and get rid of uppercaseString() calls in our code.
Flags: needinfo?(sarentz)
| Assignee | ||
Comment 8•10 years ago
|
||
Wait do we want just the first letter capitalized? For that we would use capitalizedStringWithLocale instead (https://developer.apple.com/library/mac/documentation/Cocoa/Reference/Foundation/Classes/NSString_Class/#//apple_ref/occ/instm/NSString/capitalizedStringWithLocale:).
Comment 9•10 years ago
|
||
No, this is TITLE CAPS.
I tried a few variations in the playground, all of which were wrong. The only good solution is for localizers to do the work.
Comment 10•10 years ago
|
||
(In reply to Stephan Leroux [:sleroux] from comment #6)
> If that doesn't work, would the solution for this issue be to remove any
> 'force' capitalization (calls to uppcaseString() we make in our code and
> rely on the strings provided from localizers for this?
Yes. Also consider that some locales simply don't like uppercase, and I have yet to find an usability study that confirms if using uppercase to convey meaning makes sense ("look, I'm an header" or "I'm more important than what's around me").
Just to give you a glance of the complexity using CSS
http://codepen.io/flodolo/pen/KpqYjX
Given Webkit's poor support, I'd be kind of surprised to find iOS in better shape.
| Assignee | ||
Updated•10 years ago
|
Assignee: nobody → sleroux
| Assignee | ||
Comment 11•10 years ago
|
||
Removing uppercaseString calls changes the following strings from being uppercased:
L268 - HistoryPanel.swift
NSLocalizedString("Today", comment: "History tableview section header")
NSLocalizedString("Yesterday", comment: "History tableview section header")
NSLocalizedString("Last week", comment: "History tableview section header")
NSLocalizedString("Last month", comment: "History tableview section header")
L159 - SearchSettingsTableViewController.swift
NSLocalizedString("Default Search Engine", comment: "Title for default search engine settings section.")
NSLocalizedString("Quick-search Engines", comment: "Title for quick-search engines settings section.")
L815 - SettingsTableViewController
NSLocalizedString("General", comment: "General settings section title")
NSLocalizedString("Support", comment: "Support section title")
NSLocalizedString("About", comment: "About settings section title")
NSLocalizedString("Privacy", comment: "Privacy section title")
Attachment #8652857 -
Flags: review?(sarentz)
Attachment #8652857 -
Flags: feedback?(francesco.lodolo)
Comment 12•10 years ago
|
||
Does English still wants to use uppercase? In that case we need new strings like TODAY, YESTERDAY, etc. (without removing the existing one, per discussion on branching for v-whatever-the-next-version-is).
Comment 14•10 years ago
|
||
No, we don't need to stick with all caps in English. Sentence case (Today, Yesterday, Last week, Last month) is fine.
Flags: needinfo?(randersen)
Comment 15•10 years ago
|
||
Comment on attachment 8652857 [details] [review]
https://github.com/mozilla/firefox-ios/pull/977
Looks good to me.
Attachment #8652857 -
Flags: feedback?(francesco.lodolo) → feedback+
Comment 16•10 years ago
|
||
As part of this fix, shouldn't we also change the strings to uppercase so that the localizers know that they need to uppercase their versions?
Comment 17•10 years ago
|
||
(In reply to Stefan Arentz [:st3fan] from comment #16)
> As part of this fix, shouldn't we also change the strings to uppercase so
> that the localizers know that they need to uppercase their versions?
I think we just agreed that English won't use uppercase (comment 14), so I don't see locales using uppercase either.
Updated•10 years ago
|
Attachment #8652857 -
Flags: review?(sarentz) → review+
| Assignee | ||
Comment 18•10 years ago
|
||
Merged
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•