Example xml file to show brainstorm file format

<?xml ...>
<brainstorm> - main container
  <header> - file information
    <title>Name of Model</title>
    <author>Author Name</author>
    <lastModified>2010-11-11T12:34:45Z</lastModified>
    maybe other stuff like licence etc?
  </header>

  <display> - general display options
    <background bgcolor="dddddd"/>
    <font face="Arial" textcolor="000000"/>
  </display>

  <nodes> - all nodes first with ids
    <node id="n1" label="nodename" textcolor="ff0000" posx="452" posy="82"/>
    ... other nodes ...
  </nodes>

  <connections>
    <connection source="n1" dest="n2" thickness="1"/>
    .. other connections ...
  </connections>
</brainstorm>


pseudo-DTD:

brainstorm (reqd) : header? display? nodes connections
header : title? author? lastModified?
display : background? font?
nodes (reqd) : node+ (1 or more nodes)
node (reqd) : id label? textcolor? posx? posy?
connections (reqd) : connection+ (1 or more)
connection (reqd) : source dest thickness?


Notes:
When saving as a storm file, should get option whether to save node positions or not. If not saved, then posx and posy attributes are omitted from file and randomly recalculated on load.
When loading a storm file, a list of warnings should be built (nodes with duplicate ids, connections referring to nonexistent nodes, split trees etc) and presented to user.
If you add a new connection, how can you delete it again without a way to select it?
If you delete a node, how can you make sure the storm isn't split into two/more?  Or should that be possible?  2 substorms would push each other away (unless repulsion has maximum range?)
Is it possible to have no nodes at all?  Or is there always at least one?  Prevent deletion of last one?
Should clicking on a blank canvas allow adding of a new node?  Or how do you start without loading a file?
