|
1 <?xml version="1.0" encoding="utf-8"?> |
|
2 <!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. --> |
|
3 <!-- This component and the accompanying materials are made available under the terms of the License |
|
4 "Eclipse Public License v1.0" which accompanies this distribution, |
|
5 and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". --> |
|
6 <!-- Initial Contributors: |
|
7 Nokia Corporation - initial contribution. |
|
8 Contributors: |
|
9 --> |
|
10 <!DOCTYPE concept |
|
11 PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd"> |
|
12 <concept id="GUID-2B7F7484-3A44-4A96-9B5D-79DF8A09115A" xml:lang="en"><title>How resource |
|
13 files work</title><prolog><metadata><keywords/></metadata></prolog><conbody> |
|
14 <p>In the Symbian platform, <xref href="GUID-5F749184-C804-41FC-BA81-038783BDC967.dita">resource</xref> files |
|
15 are used to define UI components used in applications. See <xref href="GUID-0FB60233-993A-4BF2-9E8C-E03AD092359B.dita">Managing |
|
16 resource files</xref> for information on defining the data structure.</p> |
|
17 <p>The following resource files are typically used as source files in Symbian |
|
18 applications:</p> |
|
19 <ul> |
|
20 <li><p><codeph>.rss</codeph> – resource source files used for UI |
|
21 components in the application. For more information, see <xref href="GUID-EC49B54F-7724-433B-BD7F-201DE3B7DAA6.dita">Resource |
|
22 file structure</xref>, <xref href="GUID-23A60DE7-B72D-41BD-9F1E-882D31A7E3C7.dita">Required |
|
23 resource file statements</xref>, and <xref href="GUID-2C74E932-B1CA-434B-AF96-66D52D689620.dita">Optional |
|
24 resource file statements</xref>.</p> |
|
25 </li> |
|
26 <li><p><codeph>_reg.rss</codeph> – resource source file used for |
|
27 registration. For more information, see <xref href="GUID-BF1AAA0D-DF2F-4E1D-A0D2-F419BD32F97A.dita">Creating |
|
28 registration resource files</xref>.</p> |
|
29 </li> |
|
30 <li><p><codeph>.hrh</codeph> – resource header file used to define |
|
31 enumerated sets of values. For more information, see <xref href="GUID-D52E98C3-F5EE-4CE1-A4F5-2EF41A066B8A.dita">Creating |
|
32 resource header files</xref>.</p> |
|
33 </li> |
|
34 <li><p><codeph>.rls</codeph> – localization files used as a source |
|
35 for UI texts strings in applications, and for managing these texts. For more |
|
36 information, see <xref href="GUID-E111C4E8-1342-4E87-ACB4-5B630AF1501C.dita">Internationalization |
|
37 and localization</xref>.</p> |
|
38 </li> |
|
39 </ul> |
|
40 <p>The structures and symbolic IDs of the files are used in various ways |
|
41 in your code.</p> |
|
42 <p> The resource files above are then compiled to yield the following files:</p> |
|
43 <ul> |
|
44 <li><p><codeph>.rsc</codeph> or <parmname>rNN</parmname>, where |
|
45 NN is a two number Symbian locale ID - compiled, machine-readable resource |
|
46 files used by the application.</p></li> |
|
47 <li><p><codeph>.rsg</codeph> - generated resource header file containing |
|
48 the symbolic IDs of the resources for inclusion into your code.</p></li> |
|
49 <li><p><codeph> _reg.rsc</codeph> or <parmname>_reg.rNN</parmname>, |
|
50 where NN is a two number Symbian locale ID - compiled, machine-readable resource |
|
51 file used for registration .</p></li> |
|
52 </ul> |
|
53 |
|
54 <p>The <parmname>rsc</parmname>, <parmname>rNN</parmname>, |
|
55 and <parmname>_reg.rsc</parmname> files need to be included in your <parmname>.sis</parmname> installation |
|
56 file so that they are placed in the device when the application is installed.</p> |
|
57 |
|
58 <p>When the application framework launches an application, it loads the |
|
59 application resource file. The application framework compares the system locale |
|
60 language setting with the available resource files, and loads the resource |
|
61 file whose extension matches the locale language code. If there is no match, |
|
62 then the system loads the resource file with the <parmname>.rsc</parmname>.</p> |
|
63 </conbody></concept> |