The new led font is now antialiased (`a la Andy) and has
[fg:toms-fgdata.git] / Aircraft / Instruments / navcom-radio.xml
1 <?xml version="1.0"?>
2
3 <!--
4 Default NAVCOM  radio instrument.
5 Parameterized and improved
6 John Check <j4strngs@rockfish.net>
7 June 2001
8
9 This is an instrument configuration file for the open-source flight
10 simulator FlightGear (www.flightgear.org).  The file is an XML-encoded
11 FlightGear property list defining the instrument's layers and actions.
12
13 Each instrument is composed of layers stacked on top of each other.
14 A layer may be a texture (with transparent parts to show the layers
15 underneath), text, or a special layer that switches between two
16 others (say, to turn an indicator light on or off).  Each layer can
17 move independently in proportion to a property value, and text
18 can be generated from property values as well: all of the layer's
19 movements are defined as transformations.
20
21 Actions are hotspots on the instrument that will respond to a mouse
22 click.  Actions always modify the values of properties, either by
23 adjusting them, toggling them, or swaping them with other
24 properties' values.
25 -->
26
27 <PropertyList>
28  
29  <name>NavCom Radio</name>
30  <w-base>256</w-base>
31  <h-base>64</h-base>
32
33  <params>
34   <comm-freq-selected-prop>/radios/comm[0]/frequencies/selected-mhz</comm-freq-selected-prop>
35   <comm-freq-standby-prop>/radios/comm[0]/frequencies/standby-mhz</comm-freq-standby-prop>
36   <nav-freq-selected-prop>/radios/nav[0]/frequencies/selected-mhz</nav-freq-selected-prop>
37   <nav-freq-standby-prop>/radios/nav[0]/frequencies/standby-mhz</nav-freq-standby-prop>
38   <nav-morse-id-volume-prop>/radios/nav[0]/volume</nav-morse-id-volume-prop>
39   <nav-morse-ident-toggle-prop>/radios/nav[0]/ident</nav-morse-ident-toggle-prop>
40  </params>
41
42  <layers>
43
44  <layer>
45    <name>background</name>
46    <texture>
47     <path>Aircraft/Instruments/Textures/navcom-radios.rgb</path>
48     <x1>0.0</x1>
49     <y1>0.75</y1>
50     <x2>1.0</x2>
51     <y2>1.0</y2>
52    </texture>
53   </layer>
54
55   <layer>
56    <name>nav frequencies</name>
57    <type>text</type>
58    <font>led</font>
59    <point-size>7</point-size>
60    <color>
61     <red>1.0</red>
62     <green>0.5</green>
63     <blue>0.0</blue>
64    </color>
65    <chunks>
66     <chunk>
67      <type>number-value</type>
68      <property alias="../../../../../params/nav-freq-selected-prop"/>
69      <format>%.2f</format>
70     </chunk>
71     <chunk>
72      <type>number-value</type>
73      <property alias="../../../../../params/nav-freq-standby-prop"/>
74      <format>%8.2f</format>
75     </chunk>
76    </chunks>
77    <transformations>
78     <transformation>
79      <type>x-shift</type>
80      <offset>5</offset>
81     </transformation>
82     <transformation>
83      <type>y-shift</type>
84      <offset>5</offset>
85     </transformation>
86    </transformations>
87   </layer>
88
89   <layer>
90    <name>com frequencies</name>
91    <type>text</type>
92    <font>led</font>
93    <point-size>7</point-size>
94    <color>
95     <red>1.0</red>
96     <green>0.5</green>
97     <blue>0.0</blue>
98    </color>
99    <chunks>
100     <chunk>
101      <type>number-value</type>
102      <property alias="../../../../../params/comm-freq-selected-prop"/>
103      <scale>0.999992</scale>
104      <!--The above is to ensure that 25kHz increments with an undisplayed last 0.005 are always
105      rounded down as occurs in real life-->
106      <format>%.2f</format>
107     </chunk>
108     <chunk>
109      <type>number-value</type>
110      <property alias="../../../../../params/comm-freq-standby-prop"/>
111      <scale>0.999992</scale>
112      <format>%8.2f</format>
113     </chunk>
114    </chunks>
115    <transformations>
116     <transformation>
117      <type>x-shift</type>
118      <offset>-119</offset>
119     </transformation>
120     <transformation>
121      <type>y-shift</type>
122      <offset>5</offset>
123     </transformation>
124    </transformations>
125   </layer>
126
127   <layer>
128   <name>nav knob</name>
129   <texture>
130    <path>Aircraft/Instruments/Textures/blister.rgb</path>
131    <x1>0.0</x1>
132    <y1>0.75</y1>
133    <x2>0.25</x2>
134    <y2>1.0</y2>
135   </texture>
136   <h>20</h>
137   <w>20</w>
138   <transformations>
139    <transformation>
140     <type>x-shift</type>
141     <offset>110</offset>
142    </transformation>
143    <transformation>
144     <type>y-shift</type>
145     <offset>-14</offset>
146    </transformation>
147   </transformations>
148  </layer>
149
150  <layer>
151   <name>voice knob</name>
152   <texture>
153    <path>Aircraft/Instruments/Textures/blister.rgb</path>
154    <x1>0.0</x1>
155    <y1>0.75</y1>
156    <x2>0.25</x2>
157    <y2>1.0</y2>
158   </texture>
159   <h>20</h>
160   <w>20</w>
161   <transformations>
162    <transformation>
163     <type>x-shift</type>
164     <offset>-17</offset>
165    </transformation>
166    <transformation>
167     <type>y-shift</type>
168     <offset>-14</offset>
169    </transformation>
170    </transformations>
171   </layer>   
172
173   <layer>
174   <name>ident knob</name>
175   <texture>
176    <path>Aircraft/Instruments/Textures/blister.rgb</path>
177    <x1>0.0</x1>
178    <y1>0.75</y1>
179    <x2>0.25</x2>
180    <y2>1.0</y2>
181   </texture>
182   <w>15</w>
183   <h>15</h>
184   <transformations>
185    <transformation>
186     <type>x-shift</type>
187     <offset>40</offset>
188    </transformation>
189    <transformation>
190     <type>y-shift</type>
191     <offset>-16</offset>
192    </transformation>
193   </transformations>
194  </layer>
195   <layer>
196    <name>ident knob pointer</name>
197    <texture>
198     <path>Aircraft/Instruments/Textures/blister.rgb</path>
199     <x1>0.0</x1>
200     <y1>0.1640625</y1>
201     <x2>0.1</x2>
202     <y2>0.328125</y2>
203    </texture>
204    <w>2</w>
205    <h>6</h>
206    <transformations>
207     <transformation>
208      <type>x-shift</type>
209      <offset>40</offset>
210     </transformation>
211     <transformation>
212      <type>y-shift</type>
213      <offset>-16</offset>
214     </transformation>
215     <transformation>
216      <type>rotation</type>
217      <property alias="../../../../../params/nav-morse-id-volume-prop"/>
218      <min>0</min>
219      <max>1</max>
220      <scale>140</scale>
221      <offset>-140</offset>
222     </transformation>
223     <transformation>
224     <type>y-shift</type>
225     <offset>3</offset>
226     </transformation>
227    </transformations>
228   </layer>
229
230   <layer>
231    <name>voice/ident toggle</name>
232    <type>switch</type>
233    <property alias="../../../params/nav-morse-ident-toggle-prop"/>
234    <layer>
235    <name>voice on</name>
236    <texture>
237     <path>Aircraft/Instruments/Textures/switches.rgb</path>
238     <x1>0.0</x1>
239     <y1>0.75</y1>
240     <x2>0.25</x2>
241     <y2>1.0</y2>
242    </texture>
243    <w>12</w>
244    <h>12</h>
245    <transformations>
246     <transformation>
247      <type>y-shift</type>
248      <offset>1</offset>
249     </transformation>
250    </transformations>
251    </layer>
252    <layer>
253    <name>ident on</name>
254    <texture>
255     <path>Aircraft/Instruments/Textures/switches.rgb</path>
256     <x1>0.0</x1>
257     <y1>0.0</y1>
258     <x2>0.25</x2>
259     <y2>0.30</y2>
260    </texture>
261    <w>12</w>
262    <h>15</h>
263    </layer>
264    <transformations>
265     <transformation>
266      <type>y-shift</type>
267      <offset>-20</offset>
268     </transformation>
269    </transformations>
270   </layer>
271
272  </layers>
273
274  <actions>
275
276   <action>
277    <name>small nav frequency decrease</name>
278    <button>0</button>
279    <x>96</x>
280    <y>-32</y>
281    <w>16</w>
282    <h>32</h>
283    <binding>
284     <command>property-adjust</command>
285     <property alias="../../../../params/nav-freq-standby-prop"/>
286     <step>-0.05</step>
287     <min>108.0</min>
288     <max>117.95</max>
289     <wrap>1</wrap>
290    </binding>
291   </action>
292
293   <action>
294    <name>large nav frequency decrease</name>
295    <button>1</button>
296    <x>96</x>
297    <y>-32</y>
298    <w>16</w>
299    <h>32</h>
300    <binding>
301     <command>property-adjust</command>
302     <property alias="../../../../params/nav-freq-standby-prop"/>
303     <step>-0.5</step>
304     <min>108.0</min>
305     <max>117.95</max>
306     <wrap>1</wrap>
307    </binding>
308   </action>
309
310   <action>
311    <name>small nav frequency increase</name>
312    <button>0</button>
313    <x>112</x>
314    <y>-32</y>
315    <w>16</w>
316    <h>32</h>
317    <binding>
318     <command>property-adjust</command>
319     <property alias="../../../../params/nav-freq-standby-prop"/>
320     <step>0.05</step>
321     <min>108.0</min>
322     <max>117.95</max>
323     <wrap>1</wrap>
324    </binding>
325   </action>
326
327   <action>
328    <name>large nav frequency increase</name>
329    <button>1</button>
330    <x>112</x>
331    <y>-32</y>
332    <w>16</w>
333    <h>32</h>
334    <binding>
335     <command>property-adjust</command>
336     <property alias="../../../../params/nav-freq-standby-prop"/>
337     <step>0.5</step>
338     <min>108.0</min>
339     <max>117.95</max>
340     <wrap>1</wrap>
341    </binding>
342   </action>
343
344
345   <action>
346    <name>small com frequency decrease</name>
347    <button>0</button>
348    <x>-36</x>
349    <y>-32</y>
350    <w>16</w>
351    <h>32</h>
352    <binding>
353     <command>property-adjust</command>
354     <property alias="../../../../params/comm-freq-standby-prop"/>
355     <step>-0.025</step>
356     <min>0.0</min>
357     <max>140.0</max>
358     <wrap>1</wrap>
359    </binding>
360   </action>
361
362   <action>
363    <name>large com frequency decrease</name>
364    <button>1</button>
365    <x>-36</x>
366    <y>-32</y>
367    <w>16</w>
368    <h>32</h>
369    <binding>
370     <command>property-adjust</command>
371     <property alias="../../../../params/comm-freq-standby-prop"/>
372     <step>-1.0</step>
373     <min>0.0</min>
374     <max>140.0</max>
375     <wrap>1</wrap>
376    </binding>
377   </action>
378
379   <action>
380    <name>small com frequency increase</name>
381    <button>0</button>
382    <x>-20</x>
383    <y>-32</y>
384    <w>16</w>
385    <h>32</h>
386    <binding>
387     <command>property-adjust</command>
388     <property alias="../../../../params/comm-freq-standby-prop"/>
389     <step>0.025</step>
390     <min>0.0</min>
391     <max>140.0</max>
392     <wrap>1</wrap>
393    </binding>
394   </action>
395
396   <action>
397    <name>large com frequency increase</name>
398    <button>1</button>
399    <x>-20</x>
400    <y>-32</y>
401    <w>16</w>
402    <h>32</h>
403    <binding>
404     <command>property-adjust</command>
405     <property alias="../../../../params/comm-freq-standby-prop"/>
406     <step>1.0</step>
407     <min>0.0</min>
408     <max>140.0</max>
409     <wrap>1</wrap>
410    </binding>
411   </action>
412
413
414   <action>
415    <name>swap nav frequencies</name>
416    <button>0</button>
417    <x>48</x>
418    <y>-32</y>
419    <w>32</w>
420    <h>32</h>
421    <binding>
422     <command>property-swap</command>
423     <property alias="../../../../params/nav-freq-selected-prop"/>
424     <property alias="../../../../params/nav-freq-standby-prop"/>
425    </binding>
426   </action>
427
428   <action>
429    <name>swap com frequencies</name>
430    <button>0</button>
431    <x>-80</x>
432    <y>-32</y>
433    <w>32</w>
434    <h>32</h>
435    <binding>
436     <command>property-swap</command>
437     <property alias="../../../../params/comm-freq-selected-prop"/>
438     <property alias="../../../../params/comm-freq-standby-prop"/>
439    </binding>
440   </action>
441
442
443   <action>
444    <name>ident volume increase</name>
445    <button>0</button>
446    <x>40</x>
447    <y>-24</y>
448    <w>8</w>
449    <h>16</h>
450    <binding>
451     <command>property-adjust</command>
452     <property alias="../../../../params/nav-morse-id-volume-prop"/>
453     <step>0.5</step>
454     <min>0</min>
455     <max>2</max>
456    </binding>
457   </action>
458
459   <action>
460    <name>ident volume decrease</name>
461    <button>0</button>
462    <x>32</x>
463    <y>-24</y>
464    <w>16</w>
465    <h>8</h>
466    <binding>
467     <command>property-adjust</command>
468     <property alias="../../../../params/nav-morse-id-volume-prop"/>
469     <step>-0.5</step>
470     <min>0</min>
471     <max>2</max>
472    </binding>
473   </action>
474  
475   <action>
476    <name>ident volume on/off</name>
477    <button>0</button>
478    <x>-6</x>
479    <y>-30</y>
480    <w>14</w>
481    <h>16</h>
482    <binding>
483     <command>property-adjust</command>
484     <property alias="../../../../params/nav-morse-ident-toggle-prop"/>
485     <step>1.0</step>
486     <min>0</min>
487     <max>1</max>
488     <wrap>1</wrap>
489    </binding>
490   </action>
491
492  </actions>
493
494 </PropertyList>