Add some boilerplate code to add support for localization

This commit is contained in:
blitzmann
2020-05-15 21:55:48 -04:00
parent ac7ccfb6a3
commit fdd06ed3d6
5 changed files with 137 additions and 1 deletions

12
locale/README.md Normal file
View File

@@ -0,0 +1,12 @@
On my Windows wsl2 (more generic explaination is needed):
`find ./gui -iname "*.py" | xargs pygettext3 -d lang -o locale/lang.pot`
This will generate the pot that should be carried over to the various language directories and renamed .po
`msgfmt -o lang.mo lang`
Run in each language directory, will compile the .po files to .mo files
## Issues
`zh_CH` doesn't seem to work. AddCatalog is not functioning. See https://discuss.wxpython.org/t/localization-not-working-with-zh-ch-addcatalog-returns-false/34628