Re: [TF-dev] Do not translate "choice" in ChoiceFormat
Michel Graciano <[email protected]>
| Newsgroups | gmane.comp.java.netbeans.modules.translated-files.devel |
|---|---|
| Message-ID | <[email protected]> |
The old problem that shows up time after time :-DJust to be warned about the problem, Masaki sent the validation page where we can see if there is this kind of problem for each language. If someone has doubt about how to solve it, just let us know. Regards. On Mon, Jun 8, 2009 at 12:13 AM, Masaki Katakai <[email protected]>wrote: > Hi Team, > > There is one important note you need to care at translation. > > I'm seeing most of you localized "choice" into your language > in message format. For example, > > TIME_HOURS={0,choice, 1#{0} hour|2#{0} hours} > > is wrongly translated into > > TIME_HOURS={0,<translation of choice>, 1#{0} <translation of hour>|2#{0} > <translation of hours>} > > It will cause java.lang.IllegalArgumentException at runtime. > In this case, correct translation is > > TIME_HOURS={0,choice, 1#{0} <translation of hour>|2#{0} <translation of > hours>} > > NetBeans uses these patters in many places. See more detail in > > http://java.sun.com/javase/6/docs/api/java/text/MessageFormat.html > > I fixed these errors at integration and updated TM for CTI. > If you translate these messages newly, please do not translate "choice". > If you find existing translation, please update the > translation and revert "choice" to English. > > Regards, > Masaki > > ./ide/glassfish-common/glassfish-common/org/netbeans/modules/glassfish/common/wizards/Bundle.properties:TIME_HOURS={0,choice, > 1#{0} hour|2#{0} hours} > ./ide/glassfish-common/glassfish-common/org/netbeans/modules/glassfish/common/wizards/Bundle.properties:TIME_MINUTES={0,choice, > 1#{0} minute|2#{0} minutes} > ./ide/glassfish-common/glassfish-common/org/netbeans/modules/glassfish/common/wizards/Bundle.properties:TIME_SECONDS={0,choice, > 1#{0} second|2#{0} seconds} > ./ide/gsf-testrunner/gsf-testrunner/org/netbeans/modules/gsf/testrunner/api/Bundle.properties:MSG_PassedTestsInfo={0,choice,0#No > test|1#1 test|1<{0,number,integer} tests} passed > ./ide/gsf-testrunner/gsf-testrunner/org/netbeans/modules/gsf/testrunner/api/Bundle.properties:MSG_FailedTestsInfo={0,choice,1#1 > test|1<{0,number,integer} tests} failed > ./ide/gsf-testrunner/gsf-testrunner/org/netbeans/modules/gsf/testrunner/api/Bundle.properties:MSG_PendingTestsInfo={0,choice,1#1 > test|1<{0,number,integer} tests} pending > ./ide/gsf-testrunner/gsf-testrunner/org/netbeans/modules/gsf/testrunner/api/Bundle.properties:MSG_ErrorTestsInfo={0,choice,1#1 > test|1<{0,number,integer} tests} caused an error > ./ide/gsf-testrunner/gsf-testrunner/org/netbeans/modules/gsf/testrunner/api/Bundle.properties:MSG_TestsInfoAllOK={0,choice,1#The > test|2#Both tests|2<All {0,number,integer} tests} passed. > ./ide/org-netbeans-spi-debugger-ui/org-netbeans-spi-debugger-ui/org/netbeans/modules/debugger/ui/actions/Bundle.properties:LBL_DebugMainProjectAction_Name=&Debug > {0,choice,-1#Main Project|0#Project|1#Project ({1})|1<{0} Projects} > ./ide/org-netbeans-spi-debugger-ui/org-netbeans-spi-debugger-ui/org/netbeans/modules/debugger/ui/actions/Bundle.properties:LBL_DebugProjectAction_Name=Run > {0,choice,0#Project|1#Project ({1})|1<{0} Projects} in Debugger > ./ide/org-netbeans-spi-debugger-ui/org-netbeans-spi-debugger-ui/org/netbeans/modules/debugger/ui/actions/Bundle.properties:LBL_DebugSingleAction_Name=Debu&g > {0,choice,0#File|1#File|1<Files} > ./ide/org-netbeans-spi-debugger-ui/org-netbeans-spi-debugger-ui/org/netbeans/modules/debugger/ui/actions/Bundle.properties:LBL_DebugTestSingleAction_Name=Debug > Test {0,choice,0#Fi&le|1#Fi&le|1<Fi&les} > ./ide/org-netbeans-spi-debugger-ui/org-netbeans-spi-debugger-ui/org/netbeans/modules/debugger/ui/actions/Bundle.properties:EXC_Illegal_attach_arguments=Illegal > {0,choice,1#value|2#values} of {0,choice,1#argument|2#arguments}: {1}. > ./ide/org-netbeans-spi-palette/org-netbeans-spi-palette/org/netbeans/modules/palette/Bundle.properties:CTL_IconSize=Show > {0,choice,1#Big|2#Small} Icons > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_CloseProjectAction_Name=&Close > {0,choice,0#Project|1#Project ({1})|1<{0} Projects} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_CloseProjectAction_Popup_Name=Close > {0,choice,0#|1#|1<{0} Projects} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_CustomizeProjectAction_Name=Project > {0,choice,0#Proper&ties|1#Proper&ties ({1})|1<Project} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_BuildProjectAction_Name=Build > {0,choice,0#Project|1#Project ({1})|1<{0} Projects} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_CleanProjectAction_Name=Clean > {0,choice,0#Project|1#Project ({1})|1<{0} Projects} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_RebuildProjectAction_Name=Clean > and Build {0,choice,0#Project|1#Project ({1})|1<{0} Projects} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_JavadocProjectAction_Name=&Generate > Javadoc{0,choice,0#|1# ({1})|1< {0} Projects} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_TestProjectAction_Name=&Test > {0,choice,0#Project|1#Project ({1})|1<{0} Projects} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_CompileSingleAction_Name=Compi&le > {0,choice,0#File|1#"{1}"|1<Files} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_RunProjectAction_Name=Run > {0,choice,0#Project|1#"{1}" Project|1<{0} Projects} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_BuildMainProjectAction_Name=&Build > {0,choice,-1#Main Project|0#Project|1#Project ({1})|1<{0} Projects} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_CleanMainProjectAction_Name=Clean > {0,choice,-1#Main Project|0#Project|1#Project ({1})|1<{0} Projects} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_RebuildMainProjectAction_Name=&Clean > and Build {0,choice,-1#Main Project|0#Project|1#Project ({1})|1<{0} > Projects} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/actions/Bundle.properties:LBL_RunMainProjectAction_Name=&Run > {0,choice,-1#Main Project|0#Project|1#Project ({1})|1<{0} Projects} > ./ide/projectui/projectui/org/netbeans/modules/project/ui/Bundle.properties:MSG_not_valid_filename=The > filename {0} is not permitted as it contains {1,choice,0#a slash (/) or a > backslash (\\)|1#a backslash (\\)}. > ./ide/projectui/projectui/org/netbeans/modules/project/ui/Bundle.properties:MSG_not_valid_folder=The > folder name {0} is not permitted as it contains {1,choice,0#a slash (/) or a > backslash (\\)|1#a backslash (\\)}. > ./ide/projectuiapi/projectuiapi/org/netbeans/modules/project/uiapi/Bundle.properties:LBL_Copy_Move_Dialog_Text={0,choice,0#Copy|1#Move} > "{1}" To: > ./ide/projectuiapi/projectuiapi/org/netbeans/modules/project/uiapi/Bundle.properties:LBL_Copying_Moving={0,choice,0#Copying > Project|1#Moving Project} > ./ide/utilities/utilities/org/netbeans/modules/search/Bundle.properties:TEXT_MSG_FOUND_X_NODES_LIMIT=Found > {1} {1,choice,1#match|1<matches} in {0} {0,choice,1#file|1<files} so far. > ./java/java-editor/java-editor/org/netbeans/modules/editor/java/Bundle.properties:WARN_CannotGoToGeneric=Cannot > perform {0,choice,0#Go to Declaration|1#Go to Source|2#Show Javadoc} here > ./java/java-hints/java-hints/org/netbeans/modules/java/hints/Bundle.properties:MSG_StaticAccess=Accessing > static {0,choice,0#field|1#method|1<element} {1} > ./java/java-hints/java-hints/org/netbeans/modules/java/hints/Bundle.properties:FIX_WrongPackageFix={0,choice,0#Remove > package declaration|1#Change package declaration to {1}} > ./java/java-hints/java-hints/org/netbeans/modules/java/hints/errors/Bundle.properties:FIX_CreateClassInPackage=Create > {2,choice,0#class|1#interface|2#enum|3#annotation type} "{0}" in package {1} > ./java/java-hints/java-hints/org/netbeans/modules/java/hints/errors/Bundle.properties:FIX_CreateClassAndCtorInPackage=Create > {2,choice,0#class|1#interface|2#enum|3#annotation type} "{0}" with > constructor "{0}({3})" in package {1} > ./java/java-hints/java-hints/org/netbeans/modules/java/hints/errors/Bundle.properties:FIX_CreateInnerClass=Create > {2,choice,0#class|1#interface|2#enum|3#annotation type} "{0}" in {1} > ./java/junit/junit/org/netbeans/modules/junit/output/Bundle.properties:MSG_PassedTestsInfo={0} > {0,choice,0#tests|1#test|1<tests} passed > ./java/junit/junit/org/netbeans/modules/junit/output/Bundle.properties:MSG_FailedTestsInfo={0} > {0,choice,0#tests|1#test|1<tests} failed > ./java/junit/junit/org/netbeans/modules/junit/output/Bundle.properties:MSG_ErrorTestsInfo={0} > {0,choice,0#tests|1#test|1<tests} caused an error > ./java/junit/junit/org/netbeans/modules/junit/output/Bundle.properties:MSG_InterruptedTestsInfo={0} > {0,choice,0#tests|1#test|1<tests} interrupted > ./java/junit/junit/org/netbeans/modules/junit/output/Bundle.properties:MSG_TestsInfoAllOK={0,choice,1#The > test|2#Both tests|2<All {0,number,integer} tests} passed. > ./platform/org-netbeans-core-startup/netbeans/core/core/org/netbeans/core/startup/Bundle.properties:MSG_also_dep_modules={0,choice,1#Another > module|1<{0} further modules} could not be installed due to the above > problems. > ./platform/org-netbeans-core-windows/org-netbeans-core-windows/org/netbeans/core/windows/view/ui/Bundle.properties:CTL_FMT_GlobalProperties={0,choice,0#No > Properties|1#{1} - Properties|2#Multiple Objects - Properties} > ./platform/org-netbeans-core-windows/org-netbeans-core-windows/org/netbeans/core/windows/view/ui/Bundle.properties:CTL_FMT_LocalProperties={0,choice,0#Properties|1#{1} > - Properties|2#Multiple Objects - Properties} > ./platform/org-openide-dialogs/org-openide-dialogs/org/openide/Bundle.properties:ACSD_NEXT={0,choice,1#Moves > to next step of the wizard.|2#Next step: {0}. {1}} > ./platform/org-openide-dialogs/org-openide-dialogs/org/openide/Bundle.properties:ACSD_PREVIOUS={0,choice,-1#Moves > to previous step of the wizard.|0#Previous step: {0}. {1}} > ./platform/org-openide-explorer/org-openide-explorer/org/openide/explorer/propertysheet/Bundle.properties:ACS_SheetButton={0,choice,0#Invalid > value {1}|1#{1}} > ./platform/org-openide-explorer/org-openide-explorer/org/openide/explorer/propertysheet/Bundle.properties:ACSD_PropertyPanelReadComponent={0} > Type: {1}{2,choice,0#|1# Bean: {3}|2# Beans: {3}} > ./platform/org-openide-loaders/org-openide-loaders/org/openide/loaders/Bundle.properties:MSG_ObjectIsTooBig=The > file {1} seems to be too large ({2,choice,0#{2}b|1024#{3} Kb|1100000#{4} > Mb|1100000000#{5} Gb}) to safely open. \n\ > ./platform/org-openide-loaders/org-openide-loaders/org/openide/loaders/Bundle.properties:LAB_EditorName={0,choice,0#{1} > [r/o]|1#{1} *|2#{1} [r/o] *|3#{1}} > ./profiler/profiler/profiler/org/netbeans/modules/profiler/actions/Bundle.properties:LBL_ProfileMainProjectAction=&Profile > {0,choice,-1#Main Project|0#Project|1#Project ({1})|1<{0} Projects}... > ./profiler/profiler/profiler/org/netbeans/modules/profiler/actions/Bundle.properties:LBL_AttachProjectAction=Attach > Profiler Using Project {0,choice,0#|1#"{1}"|1<} > ./profiler/profiler/profiler/org/netbeans/modules/profiler/actions/Bundle.properties:LBL_ProfileSingleAction40=Pro&file > {0,choice,0#File|1#"{1}"|1<File} > ./profiler/profiler/profiler/org/netbeans/modules/profiler/actions/Bundle.properties:LBL_ProfileTestAction=Profile > {0,choice,0#&Test for File|1#&Test for "{1}"|1<&Test for Files} > ./profiler/profiler/profiler/org/netbeans/modules/profiler/actions/Bundle.properties:LBL_ProfileProjectAction40=Profile > &Project {0,choice,0#|1#"{1}"|1<} > ./profiler/profiler/profiler/org/netbeans/modules/profiler/actions/Bundle.properties:LBL_UnintegrateProfilerAction=&Unintegrate > Profiler from {0,choice,0#Project|1#\"{1}\"|1<Projects} > ./profiler/profiler/profiler/org/netbeans/modules/profiler/heapwalk/memorylint/rules/Bundle.properties:{3,choice,1#'<b>one > bucket</b>'|2#{3,number,integer} buckets} > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > > -- Michel Graciano Summa Technologies do Brasil Ltda. http://www.michelgraciano.com https://genesis.dev.java.net/ http://translatedfiles.netbeans.org/index_pt_BR.html https://copypastehistory.dev.java.net/