Documentation, refactoring to use simple integer directions.
Reimplemented positionNodes using LayoutEngine.