Add ability to use XML property files for locale-specific properties
-------------------------------------------------------------------- Key: OFBIZ-1442 URL: https://issues.apache.org/jira/browse/OFBIZ-1442 Project: OFBiz Issue Type: Improvement Components: framework Reporter: Adrian Crum Priority: Minor As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Adrian Crum updated OFBIZ-1442: ------------------------------- Attachment: xml_props_demo.patch xml_props_demo.patch contains a demo in the Example component. Committers: do NOT commit this patch - it is for demonstration only. > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Adrian Crum updated OFBIZ-1442: ------------------------------- Attachment: xml_props.patch xml_props.patch contains the improvement. > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12546106 ] Adrian Crum commented on OFBIZ-1442: ------------------------------------ xml_props.patch also contains some code cleanup. Sorry about the additional changes - it was bugging me. > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Adrian Crum updated OFBIZ-1442: ------------------------------- Attachment: xml_props.patch Oops, missed something in a C&P. Improved patch. > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12546630 ] David E. Jones commented on OFBIZ-1442: --------------------------------------- This looks good Adrian. I've committed the xml_props.patch file in SVN rev 599356. I'm leaving this issue open for now because I think it would be good to use the example component as the example for this and replace the label properties files there with the XML file. > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Adrian Crum closed OFBIZ-1442. ------------------------------ Resolution: Fixed Example component updated in rev 600647. > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12550741 ] Jeroen van der Wal commented on OFBIZ-1442: ------------------------------------------- I'm not a fan of the solution of putting all languages in the same file: this makes it very hard to manage separate translation processes. I would also perfer to take a format that's supported by translations tools. I'm planning a project for a complete en consistent translation of Ofbiz into Dutch using Pootle, an online translation environment. See http://translate.sourceforge.net/wiki/ for more information about Pootle. My goal is to upload all translatable items to a Pootle site and build a community to translate all items. It could also support other languages. > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12550748 ] Adrian Crum commented on OFBIZ-1442: ------------------------------------ Jeroen, The objective of getting XML file support into OFBiz was to move away from using *.properties files - which required special translation tools. It is my understanding that there is no translation tool needed when working with UTF-8 XML files. The latest revision supports both the OFBiz custom XML file format and and standard java XML file format. While having multiple translations in the same file seems odd at first, when you look at one you can see the advantage - missing property translations become obvious. > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12550748 ] [hidden email] edited comment on OFBIZ-1442 at 12/11/07 3:40 PM: -------------------------------------------------------------- Jeroen, The objective of getting XML file support into OFBiz was to move away from using *.properties files - which required special translation tools. It is my understanding that there is no translation tool needed when working with UTF-8 XML files. The latest revision supports both the OFBiz custom XML file format and the standard java XML file format. While having multiple translations in the same file seems odd at first, when you look at one you can see the advantage - missing property translations become obvious. was (Author: [hidden email]): Jeroen, The objective of getting XML file support into OFBiz was to move away from using *.properties files - which required special translation tools. It is my understanding that there is no translation tool needed when working with UTF-8 XML files. The latest revision supports both the OFBiz custom XML file format and and standard java XML file format. While having multiple translations in the same file seems odd at first, when you look at one you can see the advantage - missing property translations become obvious. > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12550960 ] Christian Geisert commented on OFBIZ-1442: ------------------------------------------ Thinking a bit about it I think putting all translations in on XML file has some disadvantages: -the XML files will get bigger the more languages will be added (and hopefully there will be lots more) which makes it slower to process -makes it harder to patch/add new languages -if someone is changing the file with a non UTF-8 aware editor he could break for example the chinese translation (and probably won't notice it at all) (Sorry for jumping in that late...) > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12551047 ] Jeroen van der Wal commented on OFBIZ-1442: ------------------------------------------- Hi Adrian, I've worked on some huge applications which required localization and I think localization of Ofbiz (also huge) should follow roughly the same process: 1. import all translatable files into a translation tool (could be an online or offline tool); 2. let the tool build a glossary of all the terms within those files; 3. manualy tanslate and review all glossary items (can be done by non-developers); 4. build localized files using the glossary; When a new localized version of Ofbiz is needed the process starts over again but the glossary is reused so only changed or untranslated items pop up. A proper and consistent translation cannot do without tooling and should not bother the developers. In my opinion a translation should be a separate package managed by a separete team. I still don't see how your solution could avoid missing property translations. Also, adding a new localizations will be a painstaking process. I'm willing to put some time and effort to investigate in tooling for Ofbiz translations but don't want to see my options limited to none when all translations are being put in a single file. > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12551048 ] David E. Jones commented on OFBIZ-1442: --------------------------------------- There are certainly trade-offs, but I still think that the combined files are better and easier to maintain and manage than separate ones. For Christian's points: 1. the XML files will get pretty large but the processing time should still scale linearly; if not there is a bug somewhere 2. I guess this is a matter of perspective, but if I were adding a new language it would be nice to not have to have multiple files open and either jump around to those files to get the original labels or to be forced to use some sort of tool to manage the multiple files; also having multiple files to review and add to increases the chances of getting a property key wrong (which has happened a few times), and even worse on the maintenance side it makes it really prone to inconsistent property sets in different files unless a tool is used to help keep them consistent, and this is currently a bigger problem in ofbiz 3. if someone makes changes to UTF characters in a non-UTF-aware editor wouldn't the diff on the commit be huge, and result in lots of unintended line changes that would be fairly easy to spot? > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12551170 ] Jacques Le Roux commented on OFBIZ-1442: ---------------------------------------- http://translate.sourceforge.net/wiki/ is not available tonight. Inside of OFBiz I have used a such tool (the RBE plugin in Eclipse http://docs.ofbiz.org/display/OFBIZ/Plugins#Plugins-RBE) and I have tried without success to make it the official i18n/l10n tool in OFBiz community (I guess some are using it). For my part I really like to use it but it has also some drawbacks (mainly due to the inconsistent state of properties files in OFBiz). For David's points, 1. Sounds good 2. if I were adding a new language it would be nice to not have to have multiple files open and either jump around to those files to get the original labels or to be forced to use some sort of tool to manage the multiple files; RBE is this tool so far, no more comments also having multiple files to review and add to increases the chances of getting a property key wrong (which has happened a few times), Easy to deal with with RBE and even worse on the maintenance side it makes it really prone to inconsistent property sets in different files unless a tool is used to help keep them consistent Still RBE 3. No sure for foreign language (Chinese, Arab, Russian, Hebrew, etc.). In RBE you see them in their own character (but Chinese IIRW, maybe some fonts ?) To summarize my opinion, a. reality has proved that we can't have a strong policy to keep all properties files consistent. Then even with a tool like RBE, it sometimes difficult to take care of all aspects. b. I can see some advantages with a sole file, but I have to practice it before being really convinced. c. There is another annoying aspect with properties file : the way Sun deals with default language which obliges us to put -Duser.language=en in our starter files. > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12551173 ] Adrian Crum commented on OFBIZ-1442: ------------------------------------ Jacques, For Summary b - why don't you practice on the Example component? ;-) For Summary c - are you referring to design-time or run-time? > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
In reply to this post by Nicolas Malin (Jira)
[ https://issues.apache.org/jira/browse/OFBIZ-1442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12551181 ] Jacques Le Roux commented on OFBIZ-1442: ---------------------------------------- Adrian, b. I'd love, struggling with Christmas rush... (I had a look and that's why I'm not so pessimist that I'd be if I had not) c. run-time > Add ability to use XML property files for locale-specific properties > -------------------------------------------------------------------- > > Key: OFBIZ-1442 > URL: https://issues.apache.org/jira/browse/OFBIZ-1442 > Project: OFBiz > Issue Type: Improvement > Components: framework > Reporter: Adrian Crum > Priority: Minor > Attachments: xml_props.patch, xml_props.patch, xml_props_demo.patch > > > As per discussion on the dev mailing list, implement XML property files. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
Free forum by Nabble | Edit this page |