XML:Basic tutorial: Difference between revisions

m
(→‎XML tutorial for Anniversary Edition: general touch-up, mentioning patch mods and removing AETools)
Line 125: Line 125:


==Important tips for working with XML files==
==Important tips for working with XML files==
* '''capitalization rules''' (use of capital and small initial letters): You need to care about it because also Onisplit does.
* '''Capitalization matters''' -- OniSplit is case-sensitive when it processes the XML.
* '''text position in a line''': most tags have some distance towards line begin. It is not needed but preserve the overview.
* '''Text indentation''' -- most tags have some indentation (tabs). It is not needed by OniSplit but it helps one get an understanding of the hierarchy. Example:
* '''structure''': some tags have ''children''. Destroying the structure doesn't affect the reconversion but it is not good for the overview. Example:
good:
good:
     <Instance id="4" type="IGSA">
     <Instance id="4" type="IGSA">
Line 137: Line 136:
     <Instance id="4" type="IGSA"><Strings><Link>#7</Link></Strings></Instance>
     <Instance id="4" type="IGSA"><Strings><Link>#7</Link></Strings></Instance>


* '''code folding''': A simple text editor (and good use of the search function) is actually enough to work with Oni's XML. But big files might be easier to handle with what programmers call "code folding". Code folding is found in [[wikipedia:IDE|IDEs]] like [http://www.microsoft.com/express/download/ Microsoft Visual Studio] (Windows) and [http://developer.apple.com/technology/Xcode.html Xcode] (Mac). Both are free.
* '''Code folding''': A simple text editor (and good use of the search function) is actually enough to work with Oni's XML. But big files might be easier to handle with what programmers call "code folding". Code folding is found in [[wikipedia:IDE|IDEs]] like [http://www.microsoft.com/express/download/ Microsoft Visual Studio] (Windows) and [http://developer.apple.com/technology/Xcode.html Xcode] (Mac). Both are free.
: This allows you to fold whole instances and parent tags. Folded code can be previewed in Microsoft Visual Studio applications. Xcode provides an extra scroll popup.
: This allows you to fold whole instances and parent tags. Folded code can be previewed in Microsoft Visual Studio applications. Xcode provides an extra scroll popup.