Debian Codegraph @

Documentation/Overview/core_resources.xml

raw
1 <xml>
2 <head>
3 <title>Core Resources</title>
4 </head>
5 <body>
6
7 <p>ClanLib got the following core resource types:</p>
8
9 <h3>&lt;string&gt; resource</h3>
10
11 <pre>
12 &lt;string name="my_string" value="value" /&gt;
13 </pre>
14
15 <p>String resources allow an application to easilly use text strings inside
16 the program specified in a resource file. CL_String::load is used to extract
17 the value specified in a string resource.</p>
18
19 <h3>&lt;integer&gt; resource</h3>
20
21 <pre>
22 &lt;integer name="my_integer" value="value" /&gt;
23 </pre>
24
25 <p>Integer resources work the same way a string resources, except they
26 contain integer values instead of string values and are retrieved using
27 CL_Integer.</p>
28
29 <h3>&lt;float&gt; resource</h3>
30
31 <pre>
32 &lt;float name="my_float" value="value" /&gt;
33 </pre>
34
35 <p>Float resources work the same way a string resources, except they
36 contain float values instead of string values and are retrieved using
37 CL_Float.</p>
38
39
40
41 <h3>&lt;boolean&gt; resource</h3>
42
43 <pre>
44 &lt;boolean name="my_boolean" value="value" /&gt;
45 </pre>
46
47 <p>Boolean resources work just like the integer resource, but for booleans
48 and via CL_Boolean instead.</p>
49
50 <h3>&lt;raw&gt; resource</h3>
51
52 <pre>
53 &lt;raw name="my_raw" file="filename" /&gt;
54 </pre>
55
56 <p>The raw resource is a way to access a file via the resource system. A
57 &lt;raw&gt; resource is accessed inside ClanLib using the CL_Raw class. In
58 CL_Raw the file is accessable as a std::vector&lt;unsigned char&gt; (binary
59 array). Alternatively the data can be used as an input source by
60 constructing a CL_InputSource_Raw object.</p>
61
62 </body>
63 </xml>