From bda029d3eacec8207e6a99efdc7c751db5b2d85d Mon Sep 17 00:00:00 2001 From: Michael J Gruber Date: Wed, 7 Jun 2017 11:14:15 +0200 Subject: [PATCH] provide calc pdf export module constant pyoo provides FILTER_PDF_EXPORT which users may mistake as being the (non-existing) general PDF export filter, whereas in fact it is the writer export filter, which results in an "SfxBaseModel error" 0x81a when it is used for anything else but writer documents. Provide FILTER_WRITER_PDF_EXPORT and FILTER_CALC_PDF_EXPORT so that the two most used export filters are there, and their sheer presence under these names alerts the user to use the right one (or look at their value, and infer what to use for "math", "impress" etc.). FILTER_PDF_EXPORT could be deprecated but is left in for compatibility reasons for now. --- pyoo.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pyoo.py b/pyoo.py index 23e3e6b..b0ea75c 100644 --- a/pyoo.py +++ b/pyoo.py @@ -19,6 +19,8 @@ # Filters used when saving document. FILTER_PDF_EXPORT = 'writer_pdf_Export' +FILTER_WRITER_PDF_EXPORT = 'writer_pdf_Export' +FILTER_CALC_PDF_EXPORT = 'calc_pdf_Export' FILTER_EXCEL_97 = 'MS Excel 97' FILTER_EXCEL_2007 = 'Calc MS Excel 2007 XML'