Closed Bug 433319 Opened 16 years ago Closed 13 years ago

periods in sumo UI must not be hard-coded

Categories

(support.mozilla.org :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: bugzilla, Assigned: paulc)

References

Details

Attachments

(3 files)

Some periods are hard-corded and not in language.php. This make l10n harder or impossible to translate correctly especially in Japanese and some other languages who don't use periods. # Japanese use multibyte char: "。" in the end of the sentense So, don't hard-code periods in the UI text. For example: text shown in the not translated page like: This article has not yet been translated to 日本語 (ja). Perhaps you could help us with that? Just click translate this page and follow the instructions. relating entities in the (ja) language file: http://svn.mozilla.org/projects/sumo/trunk/language_files/ja/language.php // "This article has not yet been translated to" => "This article has not yet been translated to", // "Perhaps you could help us with that?" => "Perhaps you could help us with that?", // "Just click" => "Just click", // "translate this page" => "translate this page", // "and follow the instructions" => "and follow the instructions",
Is it just that one or are there many? If there are many, can you list them here and I can do them all at once.
There are quite a lot of hardcorded periods. I don't have complete list of them but I checkouted SUMO from svn and seached them with grep. I'll attach results of grep. There must be more hardcorded strings but I don't know how to find them without human check on actual UI (or source code).
This attachement is the rusult of following command: grep -R -n "{/tr}\." trunk/* This command will find lines which contain period just after {tr}...{/tr}.
Hardcorded periods found with grep part 2 This attachement is the rusult of following command: grep -R -n "\. *{tr}" trunk/* This command will find lines which contain period just before {tr}...{/tr}.
Hardcorded exclamaitons found with grep This attachement is the rusult of following command: grep -R -n "{/tr}\!" trunk/* This command will find lines which contain exclamation just after {/tr}.
My grep results nust not be the perfect list of hardcorded periods/exclamations. Please find others with smarter grep commands.
Jason, could you patch the stuff we're already aware of? Nelson, is this going to be a problem for the locales who already translated these strings? Would this depend on bug 425713?
yes, there is a dependency on bug 425713.
Depends on: 425713
probably we can write a script to look for "{/tr}."
Now that Bug 425713 is fixed, we can start to update the strings with hardcoded periods. Eric, could you create a patch that updates the strings mentioned in comment 5? Bug 425713 comment 5 explains the procedure of re-mapping the modified en-US strings with the existing translations. We should verify that this works before pushing this to production.
Assignee: nobody → smirkingsisyphus
Target Milestone: --- → 0.9
So, I'm thinking a two-stage script for this. The first will look recursively through templates/ and move any hardcoded periods into the {tr}'s (or just remove them if that's what's desired). It'll also construct a formatted list that you can feed into the second stage, which will update the language mappings. With two separate scripts, we'll be able to reuse the second one anytime bulk changes need to be made to the language mappings. Sound good or am I missing something?
Sounds awesome. Go for it! :)
Target Milestone: 0.9 → 1.0
This bug would be nice for 1.0, but we should definitely verify the accuracy of bug 425713 comment 5, which explains the procedure of re-mapping the modified en-US strings with the existing translations. Depending on Eric's status with P1 bugs, this might need to be pushed out to 1.1.
Target Milestone: 1.0 → 1.1
Target Milestone: 1.1 → 1.0
Target Milestone: 1.0 → 1.0.2
Target Milestone: 1.0.2 → Future
Target Milestone: Future → 1.3
I think we're not going to get to this until next quarter. One concern here is what we're planning to do for locales that need periods vs not. We should probably update the non-English strings to include the periods, but *not* for locales that don't use periods. We'll need to make a list of those, etc.
Target Milestone: 1.3 → 1.5
Assignee: smirkingsisyphus → paul.craciunoiu
Is it acceptable to just put the periods in for English and keep the current translation for all other locales? Note that this the side effect that periods will disappear and strings will have to be re-localized. But without a complete list of which locales have periods, we can't really differentiate.
Target Milestone: 1.5 → 1.6
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: