summaryrefslogtreecommitdiff
path: root/emfio
AgeCommit message (Collapse)AuthorFilesLines
2018-11-04tdf#55058 tdf#106084 tdf#114738 EMF+ Add rotation support for String drawingBartosz Kosiorek1-13/+13
Added rotation support for DrawString and DrawDriverString The EmfPlusDrawString record specifies text output with string formatting. The EmfPlusDrawDriverString record specifies text output with character positions. Now both EMF+ records properly support rotation. Change-Id: I15a7a6dd2b8a209cf2aac2af75d7dd89cedd1aeb
2018-08-23Resolves: rhbz#115937 virtual device leakCaolán McNamara1-1/+1
windows runs out much sooner than the other platforms Change-Id: I8ffbe32babf8854580150edfe741b03fd43e4326 Reviewed-on: https://gerrit.libreoffice.org/59408 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> (cherry picked from commit 1e918814aa4aa6d88c5426e9b28b1aea385d9a57)
2018-04-12tdf#114738 Add support for transparency for EMF+ recordsBartosz Kosiorek2-0/+26
With current EMF+ implementation all filled figures, does not support transparency. This patch add transparency support for following EMF+ records: - DrawDriverString - DrawString - FillEllipse - FillRects - FillPolygon - FillPie - FillPath - FillRegion Change-Id: I1e59ea90bdf5fafc07ff9417fccace44872bbecd Reviewed-on: https://gerrit.libreoffice.org/52021 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl> (cherry picked from commit aee1904446cd0508cdf06fd23155373b5018dfed)
2018-01-07ofz#4980 bail early with 0 pointsCaolán McNamara1-1/+1
even if start is 1 of 0 Change-Id: I7e6ad8bcd20f160e08d8795aa38e52fe3aa3cbee Reviewed-on: https://gerrit.libreoffice.org/47516 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2017-11-22replace check of eof and GetError with goodCaolán McNamara1-7/+5
Change-Id: I7d9f04262ab5420e9a14813fa1274bb9d01e3291 Reviewed-on: https://gerrit.libreoffice.org/45076 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-22drop duplicate methodCaolán McNamara1-3/+3
Change-Id: Idadd0a64e41cd02f5167b275081c3576a6224b12 Reviewed-on: https://gerrit.libreoffice.org/45075 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-21Resolves: tdf#113956 Revert ofz#3374 Integer-overflowCaolán McNamara1-1/+1
This reverts commit 304d42342bd359de97a5863febd992d2ce2f21ca.
2017-11-20ofz#4318 Integer-overflowCaolán McNamara1-3/+6
Change-Id: I7ad1f39d82e44e4fa8dd78700b25deea0c19c81a Reviewed-on: https://gerrit.libreoffice.org/44913 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-18silence some coverity warningsCaolán McNamara2-2/+2
Change-Id: I5a530e37156b5cd36e8a07ac20851880a46f520d Reviewed-on: https://gerrit.libreoffice.org/44875 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-16ofz#4230 Integer-overflowCaolán McNamara1-2/+8
Change-Id: If7c7591780fe7fa8d6fde3d17b606a4ab0acbf56 Reviewed-on: https://gerrit.libreoffice.org/44794 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-14ofz: stop at min of end of record and end of streamCaolán McNamara2-30/+41
Change-Id: I61c7cf74ea75ec56b6ccb3661f6fdd54a1ff12e1 Reviewed-on: https://gerrit.libreoffice.org/44705 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-14ofz: further limit exttextout to record size is smaller than stream sizeCaolán McNamara1-2/+2
Change-Id: I5f59db9e0c32f601537860d7574044b713d1c39d Reviewed-on: https://gerrit.libreoffice.org/44696 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-13ofz: detect short readCaolán McNamara1-1/+1
Change-Id: I1d394e914c4791a2bc3a8f3dbb1cf200e7d528fe Reviewed-on: https://gerrit.libreoffice.org/44691 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-10ofz#4158 Integer-overflowCaolán McNamara1-4/+5
Change-Id: I117156abf0e1f52491bf6bbe42bf18f4efd364f7 Reviewed-on: https://gerrit.libreoffice.org/44579 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-09rename AvoidConfig to FuzzingCaolán McNamara1-1/+1
cause that's what its really used for and a couple of cases are not specifically about avoiding config but avoiding uninteresting disk acccess and what not Change-Id: I4c6454f98388579fcd0bf9798321d30408ab65ee Reviewed-on: https://gerrit.libreoffice.org/44491 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-06loplugin:constparams in various(2)Noel Grandin2-2/+2
Change-Id: I533a7eb724b15e168a28dc92cd5962a39bc96e7c Reviewed-on: https://gerrit.libreoffice.org/44313 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-11-04ofz#4055 Integer-overflowCaolán McNamara1-3/+4
Change-Id: I15f0a48c1e0c4c03f99a74d4d9b58e064d108c72 Reviewed-on: https://gerrit.libreoffice.org/44304 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-01de-sal_uLong emfioCaolán McNamara1-10/+7
Change-Id: If1fea844350446547c9f50d0316aedd50a3f4c25 Reviewed-on: https://gerrit.libreoffice.org/44161 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-01ofz#3939 Integer-overflowCaolán McNamara1-4/+7
Change-Id: Ic35cf6dd77d536ba3ab486b1c752d81037fe7cae Reviewed-on: https://gerrit.libreoffice.org/44103 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-11-01ofz#3951 Integer-overflowCaolán McNamara1-1/+3
Change-Id: I30a6b7c00cc7895ed4c307fe0bbe685bd29217ed Reviewed-on: https://gerrit.libreoffice.org/44121 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-10-29ofz#3868 Integer-overflowCaolán McNamara1-3/+3
Change-Id: Id5de484e365567487cdeaf73f9fa88ef5a735e3e Reviewed-on: https://gerrit.libreoffice.org/44011 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-10-27tdf#111486 Fix description of SAL_ macro after EMF refactorBartosz Kosiorek2-68/+68
Change-Id: Ia4530d987e8555a5c09d49492e09079a3710b53b Reviewed-on: https://gerrit.libreoffice.org/43838 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-10-27ofz#3823 Integer-overflowCaolán McNamara1-7/+7
Change-Id: Idb8ba0972dbfe2cf6ec43caef9b6984851f8f7ca Reviewed-on: https://gerrit.libreoffice.org/43878 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-10-27emfio: don't reinvent read_uInt16s_ToOUStringMichael Stahl1-12/+1
Change-Id: Ib12923762b5dd4d255c89a5acc54fdc5678a58ed
2017-10-27remove GetSwapFloat nonsense from all 3 EMF readersMichael Stahl2-23/+0
SvStream::ReadFloat already does that, and SvStream is initialised to SvStreamEndian::LITTLE by default. Change-Id: I5859e43014533bcebef9d4b8f0678c516193b92e
2017-10-27ofz#3819 Integer-overflowCaolán McNamara1-2/+3
Change-Id: Ic45692152b039c0ee2f5659d7739c3a2517c5e83 Reviewed-on: https://gerrit.libreoffice.org/43876 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-10-26vcl: make MapMode constructor explicitMichael Stahl3-4/+4
Insert constructor everywhere, except a couple places that apparently want to compare GetMapUnit(). Change-Id: I1910deb60562e5e949203435e827057f70a3f988
2017-10-26tdf#31814 EMF/EMF+ implement dual modePatrick Jaap2-0/+19
There can be a dual mode flag set in the EMF+ data. If set, we should process either EMF or EMF+ data, because the contained information should be equal (says the documentation). The more advanced EMF+ renderer is chosen here. The flag is read in the EMFPlusReader and blocks the reading of other EMF records than HEADER, EOF and COMMENT. Thanks to Chris, for pointing out the dual mode! Change-Id: I8522930cebbb9e9ecc732397cbb3deea9e8c9127 Reviewed-on: https://gerrit.libreoffice.org/43122 Reviewed-by: Patrick Jaap <patrick.jaap@tu-dresden.de> Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl> Tested-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2017-10-25ofz#3374 Integer-overflowCaolán McNamara1-1/+1
Change-Id: If9568da924709ef523390b958ec6e8d2fd1b0e3d Reviewed-on: https://gerrit.libreoffice.org/43847 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-10-25ofz#3776 Divide-by-zeroCaolán McNamara1-2/+8
Change-Id: I2de2bfd6165a53d05e9f222908f6764a608004c3 Reviewed-on: https://gerrit.libreoffice.org/43813 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-10-25ofz#3777 Undefined-shiftCaolán McNamara1-1/+1
Change-Id: I328d939035f31acc690161b17751a5d45577f998 Reviewed-on: https://gerrit.libreoffice.org/43787 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-10-25ofz#3763 Integer-overflowCaolán McNamara1-4/+6
Change-Id: If7c10d0fd188f0aafeece9545fb138761c3a2f5b Reviewed-on: https://gerrit.libreoffice.org/43765 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-10-25ofz#3766 Integer-overflowCaolán McNamara1-1/+1
Change-Id: I0cd5810497e6baa23d10b905f35e30b694a4c12a Reviewed-on: https://gerrit.libreoffice.org/43778 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-10-24ofz Integer-overflowCaolán McNamara1-1/+4
Change-Id: I8219dfa79565601681bc236789b0b18886c4f311 Reviewed-on: https://gerrit.libreoffice.org/43745 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-10-24ofz#3743 Divide-by-zeroCaolán McNamara1-6/+14
Change-Id: I6cdc8b4c852a126c8740fc23c10f9360d8caf1a5 Reviewed-on: https://gerrit.libreoffice.org/43752 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-10-23loplugin:includeform: emfioStephan Bergmann2-2/+2
Change-Id: Icc71e73fad45d397e17ae4b6ba4967ec7a50ae27
2017-10-22check emf seekCaolán McNamara1-3/+3
Change-Id: Iace6ac3f56f2496bc43d8f2cdad630a35bc935a2 Reviewed-on: https://gerrit.libreoffice.org/43671 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-10-21check seek to end of header succeededCaolán McNamara1-12/+10
and some other checks Change-Id: I3576a9019329d23d4ce17787cbc03149fbcc475e Reviewed-on: https://gerrit.libreoffice.org/43663 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-09-30ofz+ubsanCaolán McNamara2-14/+27
Change-Id: I03f4bae4dd35eea9b5d3996e0655ca9a2ccd6a5f Reviewed-on: https://gerrit.libreoffice.org/42944 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-09-26Rename the basegfx::tools namespace to basegfx::utilsTor Lillqvist3-7/+7
Reduce potential confusion with the global tools namespace. Will hopefully make it possible to remove the annoying initial :: when referring to the global tools namespace. Unless we have even more tools subnamespaces somewhere. Thorsten said it was OK. Change-Id: Id088dfe8f4244cb79df9aa988995b31a1758c996 Reviewed-on: https://gerrit.libreoffice.org/42644 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tor Lillqvist <tml@collabora.com>
2017-09-25Conditional jump or move depends on uninitialised valueCaolán McNamara1-0/+16
Change-Id: I772c38c62950edbcde450889bae61dc37118b8cd
2017-09-23ofz#2956: Conditional jump or move depends on uninitialised valueCaolán McNamara1-1/+1
Change-Id: I399c2eb2379b23568dda83f9d41473858f33a802 Reviewed-on: https://gerrit.libreoffice.org/42699 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-09-22Fresh run of bin/update_pch.shMike Kaganski1-2/+18
Change-Id: I69d4157aaf6570cecd51ea59df20556914942e06 Reviewed-on: https://gerrit.libreoffice.org/42565 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2017-09-15consistent naming of externals: jpeg-turbo->libjpeg-turboMichael Stahl1-1/+1
Change-Id: I63fcebc36559c2698bbedd3501285a388ce8c257 Reviewed-on: https://gerrit.libreoffice.org/42291 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2017-09-04stray debuggingCaolán McNamara1-5/+0
Change-Id: Iabe56218f8914d8d858446eb177cb89dc1cd8601
2017-09-04crashtesting: uninherited GDIObj is also possible hereCaolán McNamara1-3/+8
e.g. kde239472-4.doc and W_META_CREATEPALETTE etc create objects that can be selected but are just a base GDIObj Change-Id: I4b99978c49f5abb7fb1c616d044ba25c793577be Reviewed-on: https://gerrit.libreoffice.org/41869 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-08-30Missing includeStephan Bergmann1-0/+1
Change-Id: Ic0ab1cc72005f99d7558b06c9a4ec9c94f2f0460
2017-08-30This check for GDIObj subtypes is exhaustiveStephan Bergmann1-8/+7
For one, catches issues like d5ed3cd6dbd22bb18542778f1c48f4d5b3ae0f95 "Make WinMtfFontStyle's base class EMFIO_DLLPUBLIC, too" earlier. For another, uses if/else to avoid unnecessary, expensive dynamic casts. Change-Id: I695b1e8673d5af22060b05b982789ad0ddcd39c3
2017-08-29Make WinMtfFontStyle's base class EMFIO_DLLPUBLIC, tooStephan Bergmann1-1/+1
...otherwise the dynamic_cast<WinMtfFontStyle*> in MtfTools::SelectObject (emfio/source/reader/mtftools.cxx) would not work on macOS in CppunitTest_emfio_wmf Change-Id: I5c361544fd273bdb65a4b83c7d694bae714815f5
2017-08-24emfio: unit test for the EMF+ rendererPatrick Jaap3-0/+42
Two unit tests, which test the EMF+ records DrawString and DrawLine independently. To this end, a fixed view decomposition of metafiles is implemented. The chosen primitives should be optimal, even for future extensions of the EMF+ parser. Change-Id: I12672d3b294ff0fdae63c7a5ce211517ef8f763c Reviewed-on: https://gerrit.libreoffice.org/41425 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>