summaryrefslogtreecommitdiff
path: root/emfio/qa
AgeCommit message (Collapse)Author
2021-07-07EMF+ tdf#142941 Fixes for SrcRect in DrawImagePointsBartosz Kosiorek
The SrcRect could be specified outside of source bitmap. In such cases the Destination bitmap should be displayed as shifted (eg. if position is negative), and scaled properly. Change-Id: Ied6d339703999faaae061802ef6a28e190d5a176 Change-Id: Ia9772ced282684c2c94a261d97d30b53921d6171 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118345 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl> (cherry picked from commit 4992780d2bc996c111b333549314d72f6891308d) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118304 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-07-06CppunitTest_emfio_emf: add some tolerance in TestDrawStringAlignMiklos Vajna
Commit 574dc1e8ff6ea4214fefd91216fca5146a4ff13e (EMF+ tdf#142995 tdf#142997 tdf#143076 Add alignment support for DrawString, 2021-06-24) added this test, it seems the result depends on what fonts are installed, so add some tolerance. Probably it fails for me (and not on Jenkins) as I have lots of additional fonts installed, e.g. Arial (and not only Liberation Sans). Change-Id: Ie93d1f1efe1fbbf1851ad46f33f5f83c8812e6d3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118470 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins (cherry picked from commit 4f33e723900c280c17c75898fb7a59e2e749f93e) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118492
2021-07-02EMF+ tdf#142995 tdf#142997 tdf#143076 Add alignment support for DrawStringBartosz Kosiorek
With this commit, real size of the text is used to make proper horizontal alignment. Additionally vertical alignment is added and fix for Center alignment was applied Change-Id: I17d9fd7de7f00f5e69f99c5b09061eb6059be67e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117794 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl> (cherry picked from commit 574dc1e8ff6ea4214fefd91216fca5146a4ff13e) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118257 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-06-24EMF+ tdf#142975 Add brush support to DrawString recordBartosz Kosiorek
Change-Id: Icfcb4199dcd755fb20e14a8166571b6d6e763f2e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117671 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl> (cherry picked from commit 9e8c35cc3f1f5e1c08afd46e0d0fbc07f1ff21f9) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117721 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-06-11WMF/EMF tdf#59814 tdf#142567 Fix RestoreDC recordBartosz Kosiorek
With previous implementation, the RestoreDC index argument was skipped, and always the last entry was taken. With this commit the support for reading SaveDC by specific index was added. The SaveDC/RestoreDC index support was added for both EMF and WMF, according to [MS-WMF] and [MS-EMF] documentation. Change-Id: I9b8a1a41462ae01de25ac3c85e453bcd80e05537 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117033 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-06-09WMF tdf#55058 tdf#142722 Add implementation of BitBlt and StretchBltBartosz Kosiorek
With previous implementation, only BitBlt record with 1 bit color depth was supported and StretchBlt was not implemented at all. With this commit the support for 1 bit, 24 bit and 32 bit, for both BitBlt and StretchBlt were added. Change-Id: I061b2beae8c2f143ddff9c8c8bb64bf52f4cf502 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116873 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-06-08WMF tdf#142625 Refactor Bitmap records, to better handle missing featuresBartosz Kosiorek
Change-Id: If3334158e6e0ef9bc3aa33656ad0ee45cf460dbb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116827 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-06-05WMF Change the sign of read fields in BITBLT and DIB recordsBartosz Kosiorek
Additionally the names of variables were improved, and additional checks were added for unsupported cases Change-Id: Id84ef1218c5c2a40c8d01f2d40857d892badbb9f Change-Id: I1b8571d0a627827bc1e67c2bfc6c1932d58c5233 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116744 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-31tdf#53004 tdf#142495 WMF EMF Always display Text rectangleBartosz Kosiorek
In previous implementation if BKMode was set to Transparent, then both Background of Text and Rectangle was not drawn. It was wrong, and Rectangle should be always drawn. This commit fix that issue and allows EMF images exported by LTspice to be rendered correctly under LibreOffice. Change-Id: I03801d35d92eb2a3fdc175ca1d5b348a2aa30842 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116394 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-28tdf#53004 tdf#142495 WMF EMF Fix displaying Text with OPAQUE and CLIPPEDBartosz Kosiorek
With OPAQUE option enabled, the rectangle need to be drawn, before drawing text. With CLIPPED option enabled, the text needs to be drawn only inside rectangle. In previous implementation, the rectangle read was skipped and it was not drawn (for OPAQUE). For CLIPPED the rectangle was read but Clip was not applied to text drawing This commit fix that issues, and allow to draw rectangle correctly, with BGColor (background color), and add support for Text Clipping according to [MS-WMF] and [MS-EMF] specification. The fix applied to EMR_EXTTEXTOUTW, EMR_EXTTEXTOUTA and EXTTEXTOUT records Change-Id: I0f6248bb9465e6d5f797cddb53f058afb0815a2d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116072 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-28tdf#117957 WMF Replace ellipses with rects to fix tests on arm64Bartosz Kosiorek
The issue is caused by floating numbers, On x86_64 it is: 338.499728160392-445.269903703769 on arm it is: 338.499728160392-445.26990370377 As in test files, we have two ellipses (which are made from small lines), which points rounds differently on different architectures Change-Id: I44dd5c7b3b13f3b1680d5a3a8348d6f467cb2f7c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116270 Tested-by: Jenkins Tested-by: René Engelhard <rene@debian.org> Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-05-27tdf#117957 WMF Fix failing tests on arm64Bartosz Kosiorek
So the issue is caused by floating numbers, On x86_64 it is: 338.499728160392-445.269903703769 on arm it is: 338.499728160392-445.26990370377 As in test files, we have two ellipses (which are made from small lines), which points rounds differently on different architectures Change-Id: I10efe80fea0944cf957e949c8c209c94fd588702 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116234 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-22tdf#127145 WMF Fix displaying line width in ROUNDRECT recordBartosz Kosiorek
The EDGE optimization shouldn't be used for curves, otherwise strange issues appearing. Change-Id: Id677fc9002f0f79913ae756f0e456af7c9f7e507 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115984 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-21tdf#55007 tdf#142263 tdf#142268 EMF ARC, PIE, CHORD allow to draw circleBartosz Kosiorek
In Metafile specification, if Start Point is the same as End Point, then the full circle should be drawn. Unfortunately with previous implementation, if Start Point is the same as End Point, nothing is drawn. This patch fixes that and removed EDGES optimizations, which causes display issues. Change-Id: I16a1b98f10378d57bed59696db6cc9f228044292 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115891 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-18tdf#55007 tdf#142263 tdf#142268 EMF Properly display ARC and CHORDBartosz Kosiorek
With previous implementation the ARC, ARCTO and CHORD were not displayed if the corners of rectangle was switched. With this patch the shapes are always displayed correctly. Change-Id: Ie8ac7af812298c0b96c3b5af417117784f128ce1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115757 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-15tdf#117957 WMF Add support for selecting colors from paletteBartosz Kosiorek
Change-Id: I8f995dab566d9fae79d87fe13741b8ea9658b408 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112998 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-13tdf#142014 Fix displaying strokes when line width is 0Bartosz Kosiorek
Change-Id: I80e05ff2f24f5da2f5c124c0ee1b302a1c8226ea Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115570 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-12tdf#112603 tdf#142014 tdf#142139 WMF/EMF Fix line widthBartosz Kosiorek
Previosly line width was always 1, and changing width do not affect line. Change-Id: I462096b915e053fa089e85860f124466b650558a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115497 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-11tdf#141982 tdf#142139 Add rotation and line width support to ROUNDRECTBartosz Kosiorek
With this commit the ROUNDRECT is able to change line width and transformation (including rotation) is supported. Change-Id: Ic303a74adf0fd0dd452353f250a13140603d492e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115429 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-07tdf#55058 tdf#141982 EMF: Add rotation support for INTERSECTCLIPRECT recordBartosz Kosiorek
With this commit the rotation support was added for INTERSECTCLIPRECT. Before that change rotation was not applied to these CLIP rectangles. Change-Id: I3da66790e0aeeaaeeb28d2fc30780cba8dbda390 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115102 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-06tdf#55058 tdf#141982 EMF: Add rotation support for ARC, ARCTO, CHORD, PIEBartosz Kosiorek
Change-Id: I5d9b76f0ddd2b7f12604f472986dd95976a8b04d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115185 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-06tdf#142004 tdf#141982 EMF Import: Add rotation and path support for EMR_ELLIPSEBartosz Kosiorek
Previous implementation of EMR_ELLIPSE, doesn't support rotation and EMR_ELLIPSE was not work with EMR_BEGINPATH, EMR_ENDPATH and EMR_ABORTPATH The EMR_BEGINPATH opens path bracket construction. Once path bracket construction is open, an application can begin specifying records to define the points that lie in the path. Path bracket construction MUST be closed by an EMR_ABORTPATH or EMR_ENDPATH record. With this patch all these issue was resolved for EMR_ELLIPSE Change-Id: I6d352e0ff0326dd788d43272bf1330fa6c777df4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115101 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-05-05tdf#55058 tdf#141982 EMF: Add rotation and path support for RECTANGLE recordBartosz Kosiorek
Previous implementation of EMR_RECTANGLE, doesn't support rotation and EMR_RECTANGLE was not work with EMR_BEGINPATH, EMR_ENDPATH and EMR_ABORTPATH The EMR_BEGINPATH opens path bracket construction. Once path bracket construction is open, an application can begin specifying records to define the points that lie in the path. Path bracket construction MUST be closed by an EMR_ABORTPATH or EMR_ENDPATH record. With this patch all these issue was resolved for EMR_RECTANGLE Change-Id: Ic51442df8905e47c92eed811cc776762c9752af2 Change-Id: I111f183e509f03c0b276a038680f61156b37b235 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115065 Tested-by: Jenkins Tested-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl> Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-04-23CppunitTest_emfio_emf: avoid --disable-pdfium failureMiklos Vajna
'make check' now passes for me without pdfium, all relevant tests are annotated to skip asserts when there is no pdfium anyway. Change-Id: Ie22a2b3b42d16e72f9d34ada85dee264d79d5155 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114523 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2021-04-03tdf#37281 tdf#45820 tdf#48916 tdf#55058 EMF Implement complex clippingBartosz Kosiorek
As the visual glitches were resolved with: https://gerrit.libreoffice.org/c/core/+/113423 It is time for enabling complex clipping. Change-Id: I12edc88fc9a55c8deedf3d87faeb50cfe0067a01 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113520 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-03-31tdf#55058 tdf#141394 EMF FILLRGN record is not displayed correctlyBartosz Kosiorek
The EMR_FILLRGN record fills the specified region by using the specified brush. After deep analyse of [EMF] documentation, it seems that bounds from RegionDataHeader was treated as first rectangle of region. As a result whole bounds was treated as the Region. Change-Id: Ie34877b71292c05a1f17381a6de51aaed2386565 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113423 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-03-19tdf#35986 tdf#140271 EMF Fix line width of CREATEPEN recordBartosz Kosiorek
According to [MS-EMF] documentation: "If the pen type in the PenStyle field is PS_COSMETIC, this value MUST be 0x00000001." Unfortunately based on observation of EMF import, it seems that it is not true. As a result the implementation must be partially reversed. Change-Id: I0c2ec5e26b710e1a12d5196b6c8be4709f26dc4f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112651 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2021-02-12fix test for tdf#137413Luboš Luňák
The test tested for the topleft corner to be transparent and not black, but the bitmap has a black outline, so the corner actually should be black, unlike the rest of the bitmap. I have no idea how the test could have possibly passed (and those #if tests indicate that it correctly failed with most drawing backends). What apparently enabled this to pass was commit 828504974d70111e, which made the drawing use DrawTransformedBitmap() implementation in the VCL backends, and the Cairo one apparently mishandles it. Reverting 828504974d70111e made the test fail. This commit fixes (and simplifies) the test. Change-Id: I1560849d683558abbe0cde816c4505b9824a0692 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110769 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-12-29loplugin:stringviewparam: operator +Stephan Bergmann
Change-Id: I044dd21b63d7eb03224675584fa143009c6b6008 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108418 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-24vcl: move access functions into appropriate bitmap access filesChris Sherlock
Split class functions into BitmapInfoAccess.cxx, BitmapReadAccess.cxx and BitmapWriteAccess.cxx Split header files into BitmapInfoAccess.hxx and BitmapReadAccess.hxx Change-Id: I7dcbe1d26c5b64d297658a6b809c93d7ad7f053d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108039 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-12-03EMF: tdf#138467 Fix MapMode translationBartosz Kosiorek
Add proper translation for map mapping modes: MM_LOMETRIC = 0x02, MM_HIMETRIC = 0x03, MM_LOENGLISH = 0x04, MM_HIENGLISH = 0x05, MM_TWIPS = 0x06 according to MS-EMF documentation. Change-Id: If4c71b52e5236441837e62590797ced8acd6c80f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106251 Tested-by: Jenkins Tested-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2020-11-14tdf#35986 EMF import: Add support for PS_COSMETIC line style in CREATEPENBartosz Kosiorek
When the PS_COSMETIC line style is set in CREATEPEN, line width should be set to one logical unit and a style that is a solid color This patch is fixing that, allowing to properly import EMF file. The corresponding unit tests were added Change-Id: I1a0caf6382d9c313d9725d0b94e2fcd37122a099 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105790 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-11-14tdf#35986 tdf#92315 tdf#116335 tdf#116622 Add support for MapMode TEXTBartosz Kosiorek
To properly import some EMF files, the proper implementation of MapMode Text needs to be done according to MS documentation. I have also added regression tests. Change-Id: Id788294a498b93bebb62118d13ea545f80a60f01 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105771 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-11-12tdf#42949 Fix new IWYU warnings in directories [e-f]*Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I963aa5fb892a0be36212fd0587b69f217f017947 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105469 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de>
2020-10-27tdf#137413 EMF import: fix transparency in the PDF fallback caseMiklos Vajna
Commit d75c5b38911557173c54a78f42ff220ab3918573 (tdf#136836 emfio: speed up import of EMF import when the orig PDF is available, 2020-09-17) improved both performance and correctness of the EMF import, in case it had a PDF fallback. It turns out that PDF fallback can be nominally non-transparent, and still the EMF equivalent supports transparency. Fix the problem by enabling transparency in the PDF-in-EMF case. Change-Id: I4d1585a5db6f28bd9c9cb380b5f193f4d5edcc8d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104849 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2020-09-18[API CHANGE] tdf#136836 emfio: set size hint on inner PDF if used as shape fillMiklos Vajna
The bugdoc has a shape, its bitmap fill is an EMF, which is actually a PDF. The PDF is has a height of 5cm, but the shape has a height of 14 cm. Inform vcl::RenderPDFBitmaps() about the size of the shape, so the result won't be blurry. This approach makes sure that we don't unconditionally render at higher resolution, i.e. the "load a PDF of 100 pages into Online" use-case won't use more memory than before. API CHANGE, because the EMF reader is only available via UNO, though it's likely that no actual external code would ever invoke it directly. Change-Id: If1d8def0136d408a31a0cc54777a7f26430a0ff3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102996 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2020-07-13move Primitive2dXmlDump from drawinglayer::tools to drawinglayer NSTomaž Vajngerl
drawinglayer::tools causes conflicts with ::tools namespace, so better to move Primitive2dXmlDump out from this namespace as for inspecting purposes it ccan be injected into existing code which could break make it conflict and break compilation. Change-Id: I5f9e594b2b8b1dd24067fa5f5ca3cfc4eefb85cd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98627 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-05-07fix memory leak of xmlDoc objectsNoel Grandin
in unit tests Change-Id: Id16731bbbe2f1b0e3642722d77aba04fc98db4cc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93508 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-03-16tdf#124424 EMF+ Extend test options of SvgLinearGradientPrimitive2DBartosz Kosiorek
The extended options were used in LinearGradient tests Change-Id: I44336edda2d82f936b6e931668bdac46ee7899e2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90541 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2020-03-15tdf#124424 EMF+ Add tests for LinearGradientBartosz Kosiorek
Change-Id: I85dadb067c4e77b47504dee8bb11b4c15b6ead8d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90536 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2020-02-16clang-format c*,d*,e* with under 5-percent lines of changeMuhammet Kara
Files which could become clang-format conformant with under 5-percent lines of change relative to the total count of lines in the file are found by using bin/find-clang-format.py, and fixed with /opt/lo/bin/clang-format -i <path-of-the-file> There will be follow-up patches to fix all 'under-5-percent' files. Change-Id: I06087a1385ca9da6a28d36ea4c0d2e40bdbf8f03 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88774 Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com>
2019-12-20tdf#42949 Fix IWYU warnings in emfio/Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I644bbebe798329e68665b8c751eccbb829178e91 Reviewed-on: https://gerrit.libreoffice.org/85182 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-07-05Enable many more unit tests on all archsJan-Marek Glogowski
This depends on commit "Make font-based unit test depend on instdir fonts, not that it's sure that this really fixes the problem, as its origin is really unknown. It especially enables all the font-based tests I could find on all archs. Same for many more test where I couldn't see any reason they don't work generally. To get rid of even more ifdefs, it moves these from the class to the functions, so there is actually just one needed for any test. As a result some few tests run but do nothing. There is still some problem with embedded fonts on MacOS and with delayed graphics loading on Windows, so these ifdefs are kept. Change-Id: I63f8424e9debda6cbf3e5777c93245e09f8eb0f2 Reviewed-on: https://gerrit.libreoffice.org/74719 Tested-by: Jenkins Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
2019-02-09move and extend primitive2dxmldump to drawinglayerTomaž Vajngerl
Also needs extending the XmlWriter to output double numbers as the attribute content. Change-Id: Ie749ea990d856c8c90092ed8153c24efda99c444 Reviewed-on: https://gerrit.libreoffice.org/67573 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2019-01-03svm xml dumper: move this from test to vclMiklos Vajna
This is very useful functionality, this way it can be invoked from the debugger and/or nested into an outer xml dump (sw/sd doc model dump) more easily. Change-Id: If6c83b11d0f3e65fcce71e8d820c6bc354f64d68 Reviewed-on: https://gerrit.libreoffice.org/65834 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2018-11-08tdf#113624 EMF+ Fix shift of DrawString without StringFormatBartosz Kosiorek
While we are drawing DrawString record, in most cases optional StringFormat information is available. If StringFromat information is available then we should use default values. For LeadingMargin for String the default value is 1/6 inch. Change-Id: I4a0a68df5ebe74e810f8b5864232b477b3aac255 Reviewed-on: https://gerrit.libreoffice.org/62927 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2018-11-05tdf#55058 tdf#106084 tdf#114738 EMF+ Add rotation support for String drawingBartosz Kosiorek
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 Reviewed-on: https://gerrit.libreoffice.org/62783 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2018-10-08Fix emfio_wmf_test VCL dependencyJan-Marek Glogowski
This unit test sometimes fails on Windows with the message: "no suitable windowing system found, exiting." Currently the test just depends on desktop_detector and manually sets up VCL duplicating a lot of code and even library symbols. The original Gerrit change describes a lot of failures in its comments (change 28322, version 16). Now that Windows and MacOS were converted to VCL plugins, depending on desktop_detector is not sufficient anymore. This reverts a lot of VCL test setup from commit 20f6a6b159c6 ("tdf#99402: fix Metafile Font handling"). Seems now a simple gb_CppunitTest_use_vcl is enough. Change-Id: Ia941ded91358231021741ff4a5d96e2014ac6c80 Reviewed-on: https://gerrit.libreoffice.org/61497 Tested-by: Jenkins Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
2018-04-06tdf#114738 Add support for transparency for EMF+ recordsBartosz Kosiorek
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/50609 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
2018-04-01remove unused processfactory.hxx includesJochen Nitschke
and fix fallout Change-Id: Id06bf31f2075111e426ba40c84c885ae70697bee Reviewed-on: https://gerrit.libreoffice.org/52206 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>