General tidying, things are broken
Fixed tex layer, started work on drawing layer
Numerous bugfixes

 * Introduced simple dependency injection to avoid forking on import.
   Need to find a clean way to do this on import.
 * Made TexDaemon create temporary directory and delete this.