Internationalization
Notes on internationalizing plugins
Last updated
Was this helpful?
Notes on internationalizing plugins
Last updated
Was this helpful?
This is a work in progress, but will document how to implement internationalization a plugin and provide recommendations on what needs to be internationalized.
The backbone of Java translations are a MessageBundle class. This is used to fetch strings in your plugin. Code for each of these is pretty much copy/paste across plugins. Translations are stored in properties file
TODO message bundle tutorial
TODO create message bundle code template/intellij plugin
TODO AbstractBundle (Java default) vs DynamicBundle (Intellij helper class)
In addition to the recommendations found here, documentation on specific ui elements and tutorials will have a section dedicated to internationalization. This will hopefully encourage new plugins being internationalized by default.
Might also lookup some annotations like @NLS
and @NONNLS
and provide some guidance on those and others if found
I was going to say something here about modeling property names after the plugin.xml hierarchy and things like using action ids as part of the messages.property names, but I'm still working on going through different plugins and finding out if there's an actual intuitive convention
NLS Contexts provide annotations to enforce some wording and grammar style guides (FIXME not sure if this is exactly right, but it's how I understand it)
TODO screenshots and examples of NLS contexts