rasjani/FlighToggle — Issue #5: Localize the metadata
Author: rasjani
Created: 2011-12-30 21:18:59+00:00
State: open

Localising metadata of your application

You can provide the following metadata of your Harmattan application in more than one language:

application description displayed by the Package Manager
application name displayed by the Package Manager
application name displayed in the launcher

The displayed metadata depends on the Harmattan device language settings. For example, if the selected language is Finnish, the metadata value with the Finnish language code is shown. If this does not exist, the default value is shown instead.

Note: In addition to the localised metadata fields in the control and desktop files, you must also include the default metadata that has not been localised.
Localising the description and name displayed in the Package Manager

Open the control file of your application.
To localise the name displayed for your application in the Package Manager, add a new line with the two-letter language code:

XSBC-Maemo-Display-Name-_:

To localise the description of your application, add a new line with the two-letter language code:

XB-Description-_:

If you want to provide more details on the application in the target language, start this description on the next line. You need to leave Column 1 of the line empty.

Example of localised metadata values in the control file:

In this example, the short description and the name displayed in the Package Manager are provided in the default language (English) and Finnish.

Description: An application for storing your favourite photos.
XB-Description-fi_FI: Tällä sovelluksella voit tallentaa suosikkikuvasi.
XSBC-Maemo-Display-Name: Photo Album
XSBC-Maemo-Display-Name-fi_FI: Valokuva-albumi

Localising the name displayed in the launcher

Open the .desktop file of your application.
Add a new line with the two-letter language code:

Name[]=

Example of localised metadata values in the desktop file:

In this example, the name displayed in the launcher is provided in the default language (English) and Finnish.

Name=Photo Album
Name[fi]=Valokuva-albumi