pretty lib implementation does not use **DocumentFactory**. I'ts only used in tests. In fact **test/src/tree.dart** implementation of pretty getter differs from **example/tree.dart** to deal with different factories.

I just had to rewrite these new methods to deal with factories.