summaryrefslogtreecommitdiff
path: root/drawinglayer
AgeCommit message (Collapse)AuthorFilesLines
2016-10-10Resolves: tdf#101433 reset RasterOpMode on cached virtual device before reuseCaolán McNamara1-0/+1
(cherry picked from commit 17f912c5bb63426f0758dccbc3357a73f56f3137) Change-Id: I178aa499b080b0b684d41fdd4115a6398f944c43 Reviewed-on: https://gerrit.libreoffice.org/29390 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: jan iversen <jani@documentfoundation.org> (cherry picked from commit 0537b554fd4ac56c1ac1c81e268ef1713c992cbd)
2016-07-20Give unique, comprehensible names to timers tdf#97087emahaldar/em1-1/+1
Change-Id: I9f2be193b995d43d4e3440e55a025629fe5bcaed Reviewed-on: https://gerrit.libreoffice.org/26222 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com> (cherry picked from commit e8dfe9bca7c2430df9d231ec79ed540e45f18789)
2016-07-20Replace fallthrough comments with new SAL_FALLTHROUGH macroStephan Bergmann2-3/+3
...which (in LIBO_INTERNAL_ONLY) for Clang expands to [[clang::fallthrough]] in preparation of enabling -Wimplicit-fallthrough. (This is only relevant for C++11, as neither C nor old C++ has a way to annotate intended fallthroughs.) Could use BOOST_FALLTHROUGH instead of introducing our own SAL_FALLTHROUGH, but that would require adding back in dependencies on boost_headers to many libraries where we carefully removed any remaining Boost dependencies only recently. (At least make SAL_FALLTHROUGH strictly LIBO_INTERNAL_ONLY, so its future evolution will not have any impact on the stable URE interface.) C++17 will have a proper [[fallthroug]], eventually removing the need for a macro altogether. (cherry picked from commit 14cd5182c5f64c43581c82db8c958369152226ac) Change-Id: I342a7610a107db7d7a344ea9cbddfd9714d7e9ca
2016-07-20Fix typosAndrea Gelmini1-1/+1
Change-Id: I4586168d3af81f047a4ded59fc6d257f17554885 Reviewed-on: https://gerrit.libreoffice.org/22194 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: jan iversen <jani@documentfoundation.org> Tested-by: jan iversen <jani@documentfoundation.org> (cherry picked from commit 6d68e88a0fc5a54bbb826379163bd0b9c6eae0fb)
2016-07-20vcl: bmpacc.hxx -> bitmapaccess.hxxChris Sherlock3-3/+3
(cherry picked from commit 88730cdae3520b18fc073dc59bd0ed660e15d6b4) Change-Id: I4bb19d6103c4a6a902d86b62a857e3478493924c
2016-07-20Fix typosAndrea Gelmini1-1/+1
Change-Id: Ice72f8d9971e15dd6ef365e64cd567b8581a92d3 Reviewed-on: https://gerrit.libreoffice.org/21797 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> (cherry picked from commit 534b2a4b58ba765dbc256d6297e33453524915e2)
2016-07-20vcl: rename Font::GetName to Font::GetFamilyNameChris Sherlock1-1/+1
Reviewed-on: https://gerrit.libreoffice.org/21529 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> (cherry picked from commit 28c96fc2553a5c3dee108f1e2060d7bc081a7e7e) Change-Id: Ie20871a3078bf875c1782b7761d60591a9c9704f
2016-07-20svx: remove now unused SdrModel::isTiledRendering()Miklos Vajna1-7/+4
Change-Id: I8d3c6b1de2db57e39678a7e57de6e015c72719ec (cherry picked from commit 1859acbc7c9f2548f835212f030fd1d09335ae79)
2016-07-20Fix typosAndrea Gelmini7-11/+11
Reviewed-on: https://gerrit.libreoffice.org/21209 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> (cherry picked from commit 64d624b65124ac02d8ee59b135593fd9d8eb9067) Change-Id: I9a5940027423ff0791fa7da0b79b617412ce6b86
2016-07-12Remove excess newlinesChris Sherlock105-225/+0
A ridiculously fast way of doing this is: for i in $(pcregrep -l -M -r --include='.*[hc]xx$' \ --exclude-dir=workdir --exclude-dir=instdir '^ {3,}' .) do perl -0777 -i -pe 's/^ {3,}/ /gm' $i done Reviewed-on: https://gerrit.libreoffice.org/22224 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> (cherry picked from commit a238b1f8d304bf1e2ffb357937f3ec888ee8ac89) Change-Id: Iebb93eccbee9e4fc5c4380474ba595858a27ac2c
2016-07-12update loplugin stylepolice to check local pointers varsNoel Grandin1-11/+6
are actually pointer vars. Also convert from regex to normal code, so we can enable this plugin all the time. Reviewed-on: https://gerrit.libreoffice.org/24391 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com> (cherry picked from commit e8fd5a07eca70912ddee45aaa34d434809b59fb7) Change-Id: Ie36a25ecba61c18f99c77c77646d6459a443cbd1
2016-07-12drawinglayer: fix Android-specific typoMiklos Vajna1-1/+1
The intention is to call the real function, not the template itself. Change-Id: Ib10ac4877b33554fe3a5c0918de43bea6e62cfc9 (cherry picked from commit cac70559013e575009657aa3c5168b88b1f14691)
2016-07-12drawinglayer: work around broken Android toolchainMiklos Vajna1-0/+11
Change-Id: I8679f44663aa81e04684751847cab4f06df3a71e (cherry picked from commit ce12a5021a080cc1781e0e0256af5e0085e11ef2)
2016-07-12drawinglayer, sw: indentation fixesMiklos Vajna1-1/+1
Change-Id: Ia84182629f33220a0d85bde00c16f9c26f45e3c5 (cherry picked from commit d5e07bd49ac6bcc8dc8573228e952da693241997)
2016-06-06tdf#95581: Assume tiny shears are rounding artefacts etc and can be ignoredTor Lillqvist1-1/+4
See bug report for more discussion. Change-Id: I50ee82abac4ddfbdca0fb03d17c0518860466a52 Reviewed-on: https://gerrit.libreoffice.org/25767 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2016-04-20tdf#99315 VclPixelProcessor2D: fix double border line widthMiklos Vajna5-4/+237
Regression from commit 2c91cb08d65cd35fa8ef6eaca3677aa82fb58cbe (better drawing support for borders of different width, fdo#33634, 2012-04-04), the problem is that previously the width of inner/outer double border lines got rounded to integer values quite early, but after the commit they are kept at a double precision for much longer, which needs pixel correction in VclPixelProcessor2D. Example: if the border with is 1.47, and the line gets moved by 0.2 pixels, then the inner and outer edge of the line will be 0.2 and 1.67, which gets rounded to 0 -> 2 in the pixel processor. Previously the input was rounded to 1, so moving by 0.2 resulted in 0.2 -> 1.2, which got rounded to 0 -> 1. The result is that sometimes the line width is 1 pixel wider than expected. Fix the problem by allowing VclPixelProcessor2D to request pixel correction from BorderLinePrimitive2D. It wouldn't be possible to do pixel correction only in VclPixelProcessor2D, as it has no idea what to correct: it only gets polygons, so it has no idea if e.g. the top of a polygon is the outer edge of a top border line or an inner edge of a bottom border line. Conflicts: drawinglayer/source/primitive2d/borderlineprimitive2d.cxx (cherry picked from commits 1ee570a4e625719f8bf270d372926c0d829ae6f0, 555c9add26e06030402c73f885de98f4b96826f0, 304f50684d3ac08e973fd27e6acf3e821394d164, 422f10c5d7ebe6f4b778636c9c1eb6dbdf708a27, ce12a5021a080cc1781e0e0256af5e0085e11ef2 and cac70559013e575009657aa3c5168b88b1f14691) Change-Id: I1971f3a952fbcdc598ab46c659e12d976c13cbe6 Reviewed-on: https://gerrit.libreoffice.org/24238 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Eike Rathke <erack@redhat.com>
2016-03-15vcl: move graph.[hx]xx to graphic.[hc]xxChris Sherlock9-9/+9
It's IMO a bit confusing to see a "graph" header that doesn't strictly deal with graphs, but graphics. Backporting to 5.1 series to allow for easier backporting of other potential hotfixes. Change-Id: Ic37c6cd78e23d05939486f98667144c4453bb0a3 Reviewed-on: https://gerrit.libreoffice.org/22949 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> Tested-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2016-02-18Fix missing iterator include on MSVC 14.0David Ostrovsky1-0/+1
Change-Id: I55de612aef52038fd9979426950d4ae4131ca586 Reviewed-on: https://gerrit.libreoffice.org/22448 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: David Ostrovsky <david@ostrovsky.org> (cherry picked from commit a3c70e760fa4203b7e6692f82d1d8a14214af3da) Signed-off-by: Michael Stahl <mstahl@redhat.com>
2016-02-18Missing includeStephan Bergmann1-0/+4
Change-Id: Iac9006292bfdb1b56e213346188245a205146803 (cherry picked from commit 3dc76dc72e14a48787664d6f005bbe61dd3767f0) Signed-off-by: Michael Stahl <mstahl@redhat.com>
2016-02-05tdf#91017 Enhance WMF import of EMR_ALPHABLEND actionArmin Le Grand1-3/+37
The EMR_ALPHABLEND action was added 2012/2013, but missed support for Bitmaps with Mask/Alpha. Due to that files with WMF containing these actions may look different from before. Added suport to load contained Mask/Alpha information in DIBs and the needed additional processing through the display chain. WMF import is still based on Metafile creation, when it would be using Primitives more original data could be preserved. Reviewed-on: https://gerrit.libreoffice.org/21709 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Reviewed-by: Armin Le Grand <Armin.Le.Grand@cib.de> (cherry picked from commit 6f12c93703b676b1b3839caaf2c21788e5d68477) Change-Id: I577569848cee2528328181fa0c7eb7f87857d094 Reviewed-on: https://gerrit.libreoffice.org/22053 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Armin Le Grand <Armin.Le.Grand@cib.de>
2015-12-03Missing includesStephan Bergmann1-0/+6
Change-Id: I4cefabc51c00b0e6ffd0613c4409cc31e1aa5673 (cherry picked from commit d7ceaae4cd1b31edb92c4a0987048b3405b3d346)
2015-11-27Resolves: rhbz#1283426 using vdevs based on now dead physical devs is unsafeCaolán McNamara1-5/+28
This is the same problem that commit 133e04fc1a870c0aad207e82eefeeeceaba5dc6d Author: Caolán McNamara <caolanm@redhat.com> Date: Wed Jun 17 09:23:32 2015 +0100 Resolves: tdf#91880 Invalidate graphics when the gtk window is destroyed not just when the GtkSalFrame is dtored tried to fix, but that just made it more unlikely to fail Change-Id: Icba750c787adb6cd5c5ed0874ef07e6201c4cf25 (cherry picked from commit 26c32cfee9fc9a769adba19f455e4d6c13b6d89d)
2015-11-26vcl: improve scheduler debugging information.Michael Meeks1-1/+2
Change-Id: I6f7d7d3b5b027097417a15804a42aaaab4a03158 Reviewed-on: https://gerrit.libreoffice.org/20185 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2015-11-23VirtualDevices either match another device depth, or are 1 bitCaolán McNamara1-1/+1
cairo can therefore always render to a svp virtual device with need for a fallback Change-Id: I5d03ae541820389e26f7448444444be009fb28a4
2015-11-23establish that Virtual Devices either match Physical Device depth or ...Caolán McNamara2-11/+11
are 1 or (rarely) 8 bit and lock that down. Change-Id: I3d946ebef34ffb71c5adea7aa420af50e9584e05
2015-11-17other #includes should be AFTER the include-once #defineNoel Grandin1-3/+2
found with the following script: git ls-files *.hxx | xargs perl -0777 -ne 'if (/include.* .* .* "; close ARGV }' Change-Id: I3afb0e81eb315c34bc0eb6bb4733dd1f0537d5c0
2015-11-15Fast PCH generator and optimized PCH filesAshod Nakashian1-89/+146
Ported update_pch.sh to Python with improved performance and features. The new script is invoked from the same update_pch.sh which calls it for each library in parallel, although it can be invoked directly. The ported script (update_pch) updates all PCH files in ~15 seconds where the old script took ~4500 seconds. In addition, the new script supports 3-tiered headers (system, module, and local) and is very flexible to support other improvement. It has a per-library optimal configuration settings that can be updated using another new scripts (update_pch_autotune.sh) which finds optimal per-PCH settings. PCH files have been generated using the new scripts which builds significantly faster (2-3x, depending on module and configuration) and the intermediate binaries are noticably smaller (by several GBs). The new script stamps each generated PCH file with the command that generated it to make it trivial for users to update them, and also adds the command to invoke another script (update_pch_bisect) that helps find missing headers or conflicting headers that may break the build after updating the PCH. Finally update_pch has built-in unit-tests for makefile parsing and other core functionality. Change-Id: Ib933b50e50374d7e2e7e3e95ba8799b0cc8a27fa Reviewed-on: https://gerrit.libreoffice.org/19965 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-11-12Namespace cleanup and disambiguationAshod Nakashian2-10/+10
Change-Id: Ib6d2f8b4e71436c3a7c26bdfc9847152ebaf0739 Reviewed-on: https://gerrit.libreoffice.org/19900 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-11-10loplugin:nullptr (automatic rewrite)Stephan Bergmann21-58/+58
Change-Id: I3aa15efd12b8c9b20319a1975dbbd541783aea2d
2015-11-09new loplugin: oncevarNoel Grandin1-3/+1
Change-Id: If57390510dde4d166be3141b9f658a7453755d3f Reviewed-on: https://gerrit.libreoffice.org/19815 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-11-05Reduce scope of #include <tools/poly.hxx>Matteo Casalin1-0/+1
Change-Id: I0d64393c029d27c8e6f3b6d360d2509dad16d860
2015-10-25tdf#39440: fix several warnings reported by cppcheckSerge Krot2-4/+4
Change-Id: I560d28b7cc67740c6479494d0e5aa62d2ac6ffae Reviewed-on: https://gerrit.libreoffice.org/19587 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2015-10-20loplugin:defaultparamsStephan Bergmann2-6/+2
Change-Id: Ice8e3800bab22c08daefe41eae1be706f15c004c
2015-10-13remove some useless commentsNoel Grandin1-41/+0
found with git grep '// /' Change-Id: I948cf9ae61bbbf2ec706ca5b0572c4f27c58c745
2015-10-12Replace "SAL_OVERRIDE" with "override" in LIBO_INTERNAL_ONLY codeStephan Bergmann7-10/+10
Change-Id: I2ea407acd763ef2d7dae2d3b8f32525523ac8274
2015-10-12Reduce scope of fTexStart/Stop even furtherStephan Bergmann1-3/+6
...than 92c8d74c543aa94cd512369072975dca7006d5b3 "CppCheck : reduce variables scope" did, to make it clear that it is OK to move these into the for loop: the values these variables receive (when bCreateTextureCoordinates is true) are only relevant for each immediately following call to impAddInBetweenFill, and are only actually used inside impAddInBetweenFill when bCreateTextureCoordinates (which is also passed into the call) is true. Change-Id: Ib9e315d80a04736fb6b49144c8f09239ac351c7f
2015-10-12fTexHeightPos shall be incremented across loop iterationsStephan Bergmann1-1/+1
Regression introduced with 92c8d74c543aa94cd512369072975dca7006d5b3 "CppCheck : reduce variables scope," found by clang-analyzer-deadcode.DeadStores. Change-Id: I3758a9827d4d242d4fd57af7bbb77decf2d0f327
2015-10-06Fix typosAndrea Gelmini6-12/+12
Change-Id: Ia6246bb6d37a0ec1ac53a4cb095bfd6fd15f873d Reviewed-on: https://gerrit.libreoffice.org/18945 Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2015-10-02svx, drawinglayer: handle tools Color <-> BackgroundColorPrimitive2D roundtripMiklos Vajna1-1/+3
Change-Id: Ia8c080ef50e1ddbfce17b5c5d357a240edea46f2
2015-10-02drawinglayer: add transparency support to BackgroundColorPrimitive2DMiklos Vajna1-2/+4
Impress has tools Color that is wrapped in this primitive, then later drawinglayer::processor2d::VclPixelProcessor2D::processBasePrimitive2D() converts it back to tools Color. Problem is that the primitive uses basegfx BColor, so the alpha channel is lost. Add member and API to survive this roundtrip. Change-Id: I940e60f6e352022306abac3223636d19dd859355
2015-10-01remove old standalone Sun bug numbersNoel Grandin1-1/+0
Sun bug numbers without any accompanying text are completely useless. Fixed with git grep -lP '//\s*#\d+#\s*$' | xargs perl -i -ne'/\/\/\s*#\d+#\s*$/d or print' And then hand-checking the result to restore places where it deleted code. And then some more grepping and hand-editing to kill the others. Change-Id: Ia96ce4466db8bb8da363ebf41f0ae7f45f28bf29 Reviewed-on: https://gerrit.libreoffice.org/19023 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-09-30Fix typosAndrea Gelmini5-10/+10
Change-Id: I9dbe1e05cf73af20c25392e639a807854e87fc6e Reviewed-on: https://gerrit.libreoffice.org/18946 Reviewed-by: Oliver Specht <oliver.specht@cib.de> Tested-by: Oliver Specht <oliver.specht@cib.de>
2015-09-23CppCheck : reduce variables scopeMichaël Lefèvre1-3/+4
Change-Id: Ief402017b693a4337f330fb07bb7a6dc6e749f72 Reviewed-on: https://gerrit.libreoffice.org/18753 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-09-19boost->stdCaolán McNamara2-3/+3
Change-Id: I5079e03f70370ed83a1158b2e278f48642108f08 Reviewed-on: https://gerrit.libreoffice.org/18692 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-09-16Revert "disable caching of virtual devices when OpenGL is enabled"Tomaž Vajngerl1-7/+1
Not needed anymore as the bug in OpenGL is fixed.. This reverts commit 6eff03b7d8b77b797f57f2344163ff67a99631f9.
2015-09-14boost->stdCaolán McNamara2-10/+10
Change-Id: I3fd9e1599c5ad812879a58cf1dabbcd393105e1c Reviewed-on: https://gerrit.libreoffice.org/18564 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-09-12drawinglayer: com::sun::star->cssNoel Grandin30-227/+227
Change-Id: I65706e3e87c1ce287020c90a89f7dc00866bef64 Reviewed-on: https://gerrit.libreoffice.org/18501 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-09-07cppcheck: noExplicitConstructorCaolán McNamara3-6/+4
Change-Id: I2a1add8cf526cdb305ad99ccb138454a88f2fdbd
2015-09-03disable caching of virtual devices when OpenGL is enabledTomaž Vajngerl1-1/+7
Change-Id: I15c5cca8c31d81026111a3fa3f050f53057d76b7
2015-08-17Put Polygon from tools under tools:: namespaceNorbert Thiebaud3-14/+14
Polygon is one of these names that Clash with some system objects A similar work has been done earlier with PolyPolygon. Change-Id: Icf2217cb2906292b7275760f1a16be0e150312f5 Reviewed-on: https://gerrit.libreoffice.org/17789 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com>