Namespaces

Variants
Actions

Please note that as of October 24, 2014, the Nokia Developer Wiki will no longer be accepting user contributions, including new entries, edits and comments, as we begin transitioning to our new home, in the Windows Phone Development Wiki. We plan to move over the majority of the existing entries over the next few weeks. Thanks for all your past and future contributions.

How do I compile non-Latin Symbian resource files?

From Wiki
Jump to: navigation, search

Archived.pngArchived: This article is archived because it is not considered relevant for third-party developers creating commercial solutions today. If you think this article is still relevant, let us know by adding the template {{ReviewForRemovalFromArchive|user=~~~~|write your reason here}}.

The article is believed to be still valid for the original topic scope.

Article Metadata
Compatibility
Platform(s): S60 1st Edition
S60 2nd Edition and FP1, FP2, FP3
S60 3rd Edition
S60 3rd Edition (initial release)
S60 2nd Edition (initial release)
S60 1st Edition
Article
Created: User:Technical writer 2 (07 Jul 2006)
Last edited: lpvalente (07 May 2014)

Contents

Overview

How do I compile non-Latin resource files?

Description

When creating localized versions of your application, you may need to build the resource file using strings with non-Latin characters (for example, Chinese). To achieve this, do as follows:
- Create your resource file and add the CHARACTER_SET UTF8 statement.
- Save the files in UTF8 format. If the editor allows you to save the file as UTF8 without BOM ("byte order mark"), you can skip the next step.
- Use a hexadecimal editor to remove the BOM from the saved resource file (for UTF8 the BOM is 3 bytes long with the following hexadecimal content: EF BB BF).
Example:
File: ChineseDisplay.loc

============================

CHARACTER_SET UTF8
#ifdef LANGUAGE_01
#include "Language.l01"
#endif
#ifdef LANGUAGE_31
#include "Language.l31"
#endif

============================

File: language.l01

============================

#define ELanguage            ELangEnglish
… snip ...
#define qtn_exit "Exit"
#define qtn_test "Test"
#define qtn_hello "Hello"
… snip ...

============================

File: language.l31

============================

#define ELanguage ELangPrcChinese
… snip ...
#define qtn_exit "退出"
#define qtn_test "测试"
#define qtn_hello "ä½ å¥½"
… snip ...

============================

File: ChineseDisplay.rss

============================

NAME    CHID
CHARACTER_SET UTF8
RESOURCE RSS_SIGNATURE { }
RESOURCE TBUF { buf=""; }

RESOURCE EIK_APP_INFO
    {
    menubar=r_ChineseDisplay_menubar;
    cba=R_AVKON_SOFTKEYS_OPTIONS_EXIT;
    }
… snip …
RESOURCE MENU_PANE r_ChineseDisplay_menu
    {
    items=
        {
        MENU_ITEM { command=EAknCmdExit; txt=qtn_exit; },
        MENU_ITEM { command=EChineseDisplayCmdTest; txt=qtn_test; },
        MENU_ITEM { command=EChineseDisplayCmdHello; txt=qtn_hello; }
        };
    }
… snip ...

This page was last modified on 7 May 2014, at 12:56.
47 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.

 

Thank you!

We appreciate your feedback.

×