Xml writer is ready

Add writing to xml, add programmer dialog, fix one mistake, add new
TODOs.