made the pdf export work with setter mode too and implemented the 'export grid template' menu option in all modes