Improved DOT graph generator