PropertyList XML files: Difference between revisions

Jump to navigation Jump to search
no edit summary
No edit summary
No edit summary
Line 17: Line 17:
  </PropertyList>
  </PropertyList>
</syntaxhighlight>
</syntaxhighlight>
Property typing is optional, all properties are by default string/unspecified and are transparently converted by the property tree:


<syntaxhighlight lang="xml">
<syntaxhighlight lang="xml">
Line 26: Line 28:
  </PropertyList>
  </PropertyList>
</syntaxhighlight>
</syntaxhighlight>
Indexing happens implicitly for identically named properties:
<syntaxhighlight lang="xml">
<?xml version="1.0"?>
<PropertyList>
  <foo>Hello</foo>
  <foo>Hello</foo>
  <foo>Hello</foo>
</PropertyList>
</syntaxhighlight>
so that the three foo tags become foo[0], foo[1], foo[2] in the property tree.
Indexing happens implicitly for identically named properties:
<syntaxhighlight lang="xml">
<?xml version="1.0"?>
<PropertyList>
  <foo n="0">Hello</foo>
  <foo n="1">Hello</foo>
  <foo n="2">Hello</foo>
</PropertyList>
</syntaxhighlight>
To make property settings persistent in between FlightGear sessions, use the userarchive attribute:
<syntaxhighlight lang="xml">
<?xml version="1.0"?>
<PropertyList>
  <foo userarchive="y">Hello</foo>
</PropertyList>
</syntaxhighlight>
For further information please refer to $FG_ROOT/Docs/README.introduction and


[[Category:XML]]
[[Category:XML]]
[[Category:Property Tree]]
[[Category:Property Tree]]

Navigation menu