Open dangero2000 opened 2 years ago
Thiis is actually a good idea, however it would require to some call to re.match on each spoken which would slow down the cache lookup a little bit. I certainly see your point however, although I think that very few people would edit the cache to replace such occurences with regular expressions. I'll this open for reference, but won't think I'd work on this quickly.
On the contrary; I believe people who want to translate games that don't have a native translation function would absolutely benefit from this. I forgot to mention, this will also allow people to make translations for games and make them public so that others don't have to cope with the Google Translate versions.
I opened the translation cache files in Notepad++, and I saw that the text strings were mostly in readable form. By mostly, I mean for the languages that don't use non-Latten characters. Those languages show Unicode numbers I think. I was wondering if it would be possible to edit the translation cache through an NVDA Speech Dictionaries dialogue? This way you could do things such as adding regular expressions. This would be useful in situations where you get a string of text that stays the same except for a certain part in the middle, i.e., "You have 5 pieces of gold" and "You have 6 pieces of gold". This way, the translate addon won't generate several instances of the same text, making the translation cache larger than necessary. This will also help me edit translations in the cache without having to do it manually and learn the Unicode characters.