User Tools

Site Tools


snowberry:localizing_snowberry

stub cleanup

snowberry supports localizations. This means that you have to create/download your localization file for the language you want (for example english.lang) after which Snowberry uses it while creating texts to the UI.

Changing the user interface language

It is made you easy to change UI language in Snowberry. First you have to choose Defaults profile. Then click Settings tab and then choose Snowberry category.

In Snowberry category there is a label called “Snowberry user interface language”. Choose the language that you want to use. Notice that the language in the UI changes immediately. If there is no language that you want to use, just create your own file [6.2.3] or use an existing file [6.2.2].

Using an existing localization file

If you have existing localization file, it is simple to add to Snowberry. You just have to copy localization file (for example english.lang) to the user specific folder (lang/).

After that Snowberry recognizes that you want to add new localization and it is possible to choose it [6.2.1].

Creating your own localization file

If there isn't localization that you want to use and you don't find an existing localization file, it is possible to create your own file. The structure of a localization file is simple.

First there is key element, which tells where you want to affect. After key element there is character ':' which tells you that key element ends and visible part (this is what you can see in UI) starts.

For example, one line could look like this:

profile-list: Game Profiles

Here 'profile-list' is key element and 'Game Profiles' is what you can see in UI.

One key element should be same as the string “¬Ä¬úlanguage-“¬Ä¬ù added to the beginning of the name of the file. For example, if we want to create a localization file english.lang, we should have key element 'language-english' in our localization file. The key element is string which appears in localization list. This line could look like this:

language-english: English (US)

So English (US) appears in localization list.

Almost everything in the UI is possible to change in your own language. For example button names. Key element tells you what a button does, and you can give it any name that you like to see in the UI.

For example the line for Play button line in localization file could look like this:

play: Play

So you can name all the components of the UI as you wish. All the key elements can be copied from english.lang.

You should also add comments to your localization file. Comment line begins with '#'-char and everything after that to the end of line is comment.

Here is an example of a comment line:

# $Id: english.lang,v 1.11 2005/01/19 15:41:36 jotkeran Exp $.

When your localization file is ready, you just have to save/move it in your system specific folder (lang/). Now Snowberry notices it, and your localization is available to use

See also

snowberry/localizing_snowberry.txt · Last modified: 2009-08-13 15:10 by 127.0.0.1