Removed parts of PDFWriter and doTestCode method

Gökçen Eraslan gokcen.eraslan at gmail.com
Sun Jun 10 04:13:03 PDT 2012


Hello,

I've realized that there is a great test code[1] for PDFWriter. It draws
some texts and shapes, adds annotations and widgets like buttons,
checkboxes, comboboxes etc and saves resulting pdf file in HOME
directory. It's very useful since the capabilities of the PDFWriter can
be tested with that method. I want to use that method to test PDF
signatures quickly.

The bad news is it doesn't work now :) I mean it's outdated since it's
jailed into a #ifdef DO_TEST_PDF. After some PDFWriter unusedcode.easy
cleanups[2,3] some of the calls of that test method is not available any
more.

I have commented out outdated parts and added a
com::sun::star::uno::Reference< com::sun::star::beans::XMaterialHolder >
to make it work. Patch is attached. In IRC, Tor said that writing a unit
test is a better way. Maybe I can write one.

Cheers.


[1]:
http://opengrok.libreoffice.org/xref/core/vcl/source/gdi/pdfwriter_impl.cxx#123

[2]:
http://cgit.freedesktop.org/libreoffice/core/commit/?id=581e7d7057afa87036d84e42c0e0a8a7368e20c7

[3]
http://cgit.freedesktop.org/libreoffice/core/commit/?id=09279fe3dad24ab58121e4f0a9564d252b64d81a

-- 
Gökçen Eraslan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: libreoffice-fix-dotestcode-pdf-test.diff
Type: text/x-patch
Size: 4622 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20120610/62d8702b/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 554 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20120610/62d8702b/attachment.pgp>


More information about the LibreOffice mailing list