Added: A rough implementation of export to pdf, issue #42.

Please, give me some feedback of enhancements in this function.