Restore retention of collapsed state in graph viewer on reload.

And do a little refactoring in the cylc_xdot module.

Since dumping configobj (I think) the graph viewer ("cylc graph" not gcylc graph view) was not retaining an  existing family-collapsed if the suite.rc file changed and was reloaded.  Also factored out some redundancy from the two classes derived from xdot.DotWindow - one for dependency graphs, one for runtime namespace graphs - although more could be done there (back in the day namespace graph functionality was quickly tacked on by copying the dep graph window class and making a few minor changes, and I never got back to clean up properly :-(