Menu

Using in WinForms

arbinada

Gettex.NET in WinForms

Xgettext utility extract not only strings from GetString() calls. All settings of "Text" properties will be taken in account and added into PO template file.

label1.Text = "My string";

The GNU.Gettext.WinForms.dll contains "Localizer" class that can be used to translate all text properties of the controls on the form including sub-controls. Localizer can also revert translated text values to their original state.

// Place it in form constructor or in OnLoad() event handler
GNU.Gettext.GettextResourceManager catalog = new GettextResourceManager("Examples.HelloForms.Messages");
GNU.Gettext.WinForms.Localizer.Localize(this, catalog);

WinForms application under Linux


Related

Wiki: Home

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.