[ 
https://issues.apache.org/jira/browse/TAP5-211?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12643438#action_12643438
 ] 

Ulrich Stärk commented on TAP5-211:
-----------------------------------

The majority of the world (see 
http://en.wikipedia.org/wiki/Decimal_separator#Examples_of_use) is using the 
',' char as a seperator and you are saying there is no general need?

Sure, for a simple form on some page you can just provide your own Translator 
for the respective field. But if you are using components that rely on 
translators from the TranslatorSource service (like BeanEditForm) you can't 
just contribute your own translators, you'll also have to replace the 
TranslatorSource with an implementation that uses the current user's locale, so 
a workaround is everything else but trivial. And then there is still the client 
side validation issue.

So there are two things that need to be adressed:

1. We either need to have a TranslatorSource that takes into account the 
current user's locale or extend the Translator interface
2. We need a client side parsing function that matches the server side.

Dojo (http://api.dojotoolkit.org/jsdoc/dojo/1.2/dojo.number) has a number 
parser/formatter that can handle different locales, maybe we can borrow 
something from there.

> Add localization to translators to allow for localized display/entering of 
> values
> ---------------------------------------------------------------------------------
>
>                 Key: TAP5-211
>                 URL: https://issues.apache.org/jira/browse/TAP5-211
>             Project: Tapestry 5
>          Issue Type: Improvement
>    Affects Versions: 5.0.15
>            Reporter: Ulrich Stärk
>            Assignee: Howard M. Lewis Ship
>         Attachments: TAPESTRY-2457.txt
>
>
> Localization support for pages and messages is great in Tapestry but it lacks 
> support for localization of input values because the translators don't have 
> support for it. It would be great if users could just enter numbers etc. in 
> their respective locale, e.g. use ',' instead of '.' to seperate decimal 
> places from the integer part, out of the box.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to