When we follow localization guidelines we endup with at least a couple of resource files.
Resource.resx
and Resource.CI.resx
which is a specific CultureInfo
resource.
Lets say we add a hundred string pairs in Resource.resx
and want to 开发者_开发问答translate those keys in another resource. we can copy paste them right now and translate them and it might work the first time.
However after we translate strings it becomes hard to keep files synchronized - it reorders strings automatically and I currently don't understand what is the supposed way to make sure each string is localized.
Since resource strings are supposed to be kind of linked with each other and with extra job that is done to make sure satellite assemblies are built correctly I was hoping theres a function like 'make sure each resource string is present in localized resource file' but I am afraid that one is missing..
RESX Synchroniser might do you what you are looking for
When you edit the .NET Resource files in Visual Studio, either manually and using the "Generate Local Resources" command, the IDE updates only the culture-invariant resources: if you have a resource file called Messages.aspx, the files in other languages, say Messages.it-IT.resx, are not updated, and you have to do that manually. RESX Synchronizer will help you keep the resource files synchronized, adding the new keys to the localized files, and removing the deleted ones. Comments are preserved during the process.
I just found http://zetaresourceeditor.codeplex.com/ as well seems like a similar idea to the others
may be UnitTest
can help you? you know, which text each control should have, once you create them, after just add new strings to list and compare the values. after once hard working you can test your localization works right.
a little old this discussion, but still interesting. have a look at ResXManager
I know this has already been given traditional answers, but I would also like to put forward something completely original we tried (and succeeded) doing ourselves for more efficient localisation of Silverlight:
Localisation of Silverlight projects after completion
(Resx is so "last century")
I suggest you create culture specific resource files programmatically using the Resx file for that Winform. You can create a small app which you could run time to time.
Create XML kind of file for each culture like fr.XML, fill that with the Union of all the strings in your project.And provide the translations there itself like, for example that file in french might look like the following..
< wordTranslation>
< Word>Hello< /Word>
< Translation>Bonjour< /Translation>
< /wordTranslation>
Create a hashtable or some data structure which would best act as dictionary for each culture, fill it with data from the culture specific XMl files like frDictionary.
For Each Resx file in your project for example wind1.resx , create a culture specific file like wind1.fr.resx. Read words from wind1.resx, find the translation of the word from the frDictionayry. Write it to wind1.fr.resx.
You can keep updating your translations in the XML file. So its a one time effort. This way you can keep it synchornised and easily maintainable.
You mean synchronize translations between those files? Use http://www.getlocalization.com and upload both as master files, when they are translated the translations are populated to all your files.
I think you can try Amanuens. It's developed by the same author of RESX Synchronizer and besides help keeping resource files synchronized (even automatically into your repository if you set it), can be used to give your translators access to strings to be translated in a very powerful and easy to use web editor.
精彩评论