summaryrefslogtreecommitdiff
path: root/canvas
AgeCommit message (Collapse)AuthorFilesLines
2018-01-02Fix typosAndrea Gelmini1-2/+2
Change-Id: Ida13b0649f0b6b1bb25f906ca9ad3a891b45739d Reviewed-on: https://gerrit.libreoffice.org/47262 Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com> Tested-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2017-12-26loplugin:passstuffbyref improved return in canvas and svtoolsNoel Grandin14-18/+18
and for now, ignore methods with params so we don't fall into the trap of thinking that calls to methods like: Bar& foo(Bar &p) { return p; } can be converted from Bar f() { return foo(Bar()); } to Bar const & f() { return foo(Bar()); } Change-Id: Ia3795eb2baf353cb6bec4ebf40451f2789d66ad7 Reviewed-on: https://gerrit.libreoffice.org/47034 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-20Properly skip ignored valueMike Kaganski2-2/+2
Change-Id: I1ac75cde58a52f87ef6825baa2e689dbc449c8f0 Reviewed-on: https://gerrit.libreoffice.org/46547 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2017-12-19remove unused typedefsNoel Grandin3-6/+0
Change-Id: I6fd7a9fed3a80c91a3766fceefd43c5db0aa5275 Reviewed-on: https://gerrit.libreoffice.org/46763 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-19inline use-once typedefsNoel Grandin2-4/+2
Change-Id: I5c3ffc03c26b3428f1f336e6ecba7838a1cf1157 Reviewed-on: https://gerrit.libreoffice.org/46764 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-19loplugin:unusedfieldsNoel Grandin3-13/+6
Change-Id: I84a7bcb891548416f0e1f1b20059f9b20c890d4c Reviewed-on: https://gerrit.libreoffice.org/46686 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-15loplugin:salcall (clang-cl)Stephan Bergmann2-2/+2
Change-Id: Idda630320bb5e02e1ea675b3b3786c9ec6ac166b Reviewed-on: https://gerrit.libreoffice.org/46504 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-12-11loplugin:salcall fix functionsNoel Grandin5-5/+5
since cdecl is the default calling convention on Windows for such functions, the annotation is redundant. Change-Id: I1a85fa27e5ac65ce0e04a19bde74c90800ffaa2d Reviewed-on: https://gerrit.libreoffice.org/46164 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-11loplugin:salcall (clang-cl)Stephan Bergmann1-1/+1
Change-Id: I31018af8d992c9496f01a72925e24d9b362e340d Reviewed-on: https://gerrit.libreoffice.org/46204 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-12-05loplugin:salcall fix non-virtual methodsNoel Grandin2-2/+2
first, since those are safer to change than virtual methods Change-Id: Ie3b624019d75ee2b793cee33b3c5f64e994e8bfe Reviewed-on: https://gerrit.libreoffice.org/45798 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-11-29loplugin:unnecessaryparen (clang-cl)Stephan Bergmann1-1/+1
Change-Id: I3a2b7ed3fdef3b77c0a052b10f88918aa616779e Reviewed-on: https://gerrit.libreoffice.org/45469 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-11-27loplugin:unnecessaryparenStephan Bergmann1-1/+1
Change-Id: Ie66c3bec510138b75c41d261b447c956a92486a7
2017-11-14Fix typosAndrea Gelmini1-1/+1
Change-Id: I53b47cab5cbc603bf11adcda8ac2a8373eef26a8 Reviewed-on: https://gerrit.libreoffice.org/44695 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
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-04Replace lists by vectors (canvas)Julien Nabet3-5/+4
Change-Id: I4695b1f1095a6324632f48727274bdfdcc63720b Reviewed-on: https://gerrit.libreoffice.org/44298 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2017-11-01loplugin:constantparam in c*Noel Grandin2-12/+9
Change-Id: I10c7b62e6458062324367b94b207f776af79f598 Reviewed-on: https://gerrit.libreoffice.org/44129 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-10-27loplugin:includeform: canvas (Windows)Stephan Bergmann1-2/+2
Change-Id: I67e4e72ea58f64c4c12e977a936fe1e8e4578160
2017-10-26More loplugin:unnecessaryparenStephan Bergmann1-3/+3
81892b2037453108b9bde1512a500cf3b2ce438a "loplugin:unnecessaryparen when compiling as C++17, so the ParenExpr is no longer hidden behind ExprWithCleanups/CXXConstructExpr/MaterializedTemporaryExpr wrappers" gave me the idea to generally look though IgnoreImplicit instead of IngoreImpCasts in loplugin:unnecessaryparen. However, that would still not look through implicit CXXConstructExpr, so would still not have found the occurrences in 81892b2037453108b9bde1512a500cf3b2ce438a when compiling in pre-C++17 mode. Therefore, let ignoreAllImplicit also look through CXXConstructExpr. (I am not entirely sure in which situations non-implicit CXXConstructExpr---that should thus not be ignored---would occur, but assume they would be underneath something like a CXXFunctionalCastExpr, which is not ignored.) Change-Id: I947d08742e1809150ecc34a7abe84cca5e0ce843
2017-10-23loplugin:includeform: canvasStephan Bergmann2-2/+2
Change-Id: I3d0748aa22562174c8fd6ac2eb7bb091c116fd67
2017-10-05Rename and move SAL_U/W to o3tl::toU/WMike Kaganski2-7/+4
Previosly (since commit 9ac98e6e3488e434bf4864ecfb13a121784f640b) it was expected to gradually remove SAL_U/W usage in Windows code by replacing with reinterpret_cast or changing to some bettertypes. But as it's useful to make use of fact that LibreOffice and Windows use compatible representation of strings, this commit puts these functions to a better-suited o3tl, and recommends that the functions be consistently used throughout Windows-specific code to reflect the compatibility and keep the casts safe. Change-Id: I2f7c65606d0e2d0c01a00f08812bb4ab7659c5f6 Reviewed-on: https://gerrit.libreoffice.org/43150 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2017-10-03Replace more reinterpret_cast with SAL_W/SAL_UMike Kaganski2-4/+3
Change-Id: Ia632e4083222ad9e7f17c2ad0d0825f189c700cc Reviewed-on: https://gerrit.libreoffice.org/43071 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2017-09-30Use explicit function names for fooA/fooW WinAPI; prefer fooWMike Kaganski1-1/+1
We should only use generic foo function name when it takes params that are also dependent on UNICODE define, like LoadCursor( nullptr, IDC_ARROW ) where IDC_ARROW is defined in MSVC headers synchronised with LoadCursor definition. We should always use Unicode API for any file paths operations, because otherwise we will get "?" for any character in path that is not in current non-unicode codepage, which will result in failed file operations. Change-Id: I3a7f453ca0f893002d8a9764318919709fd8b633 Reviewed-on: https://gerrit.libreoffice.org/42935 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2017-09-29loplugin:flatten check for throw in then clauseNoel Grandin1-20/+17
also make the plugin ignore the case where we have var decl's in the clause we want to flatten, which could lead to problematic extension of variable lifetime Change-Id: I3061f7104e8c6a460bf74f5eac325a516ec50c59 Reviewed-on: https://gerrit.libreoffice.org/42889 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-09-26Rename the basegfx::tools namespace to basegfx::utilsTor Lillqvist50-117/+117
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-15Add tools::Time::GetMonotonicTicks (us)Jan-Marek Glogowski2-85/+2
This moves a combination of tools::Time::GetSystemTicks(), canvas ElapsedTime::getSystemTime() and the opencl timing implementation into tools::Time::GetMonotonicTicks() as a monotonic microsecond time source. Change-Id: I5c9263540b8af55b2eeca6126e288129427f6e8e Reviewed-on: https://gerrit.libreoffice.org/41991 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-09-11clang-tidy modernize-use-emplace in c*Noel Grandin3-18/+18
Change-Id: I419d1f67ba301050d05981db2a3d6178878684a9 Reviewed-on: https://gerrit.libreoffice.org/42110 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-08-31loplugin:constparams: canvas (clang-cl)Stephan Bergmann4-7/+7
Change-Id: I892498d323acd72757a05bac05d19c62f11f7cd3
2017-08-01loplugin:checkunusedparamsNoel Grandin1-9/+0
the "check for taking address of function" part was generating false+ Change-Id: Iad6203850901229b7b1b2f8938c68ec703cd343f Reviewed-on: https://gerrit.libreoffice.org/40613 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-25use more comphelper::InitAnyPropertySequenceNoel Grandin1-14/+11
Found with: git grep -n -A10 'Sequence.*Any' -- *.cxx | grep -B5 -w PropertyValueProvider and: git grep -n 'Sequence.*Any.*( *&' Change-Id: Icb18c98bdd3f8352817e443ff78de5df042859ad Reviewed-on: https://gerrit.libreoffice.org/40389 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-24cairo_canvas: shape clipping box doesn't match where its text is renderedCaolán McNamara2-2/+2
since (I believe) commit 34d7602954d4483b3bc9db700e7df2c15348947a Date: Wed Nov 9 15:22:43 2016 +0200 tdf#55469 Consistent line spacing across platforms the point of that was to have the same line spacing on all platforms to fix the cairo text layout bounds to use the same algorithm as the generic text layout Change-Id: I26d3dec8354a9eac1423557f7d52a08f37c8843c Reviewed-on: https://gerrit.libreoffice.org/40364 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-07-20loplugin:constparams in canvasNoel Grandin12-14/+14
Change-Id: Id54bb9dca606dd91e2d3ad4b63b9af7593c601e0 Reviewed-on: https://gerrit.libreoffice.org/40202 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-13use more OUString::operator== in a*..chart2Noel Grandin1-6/+6
Change-Id: Ifb5608abebffd9687ed55e8c74f9be54a749111d Reviewed-on: https://gerrit.libreoffice.org/39887 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-06use more begin()/end() for SequenceNoel Grandin2-4/+4
Change-Id: I399be6b6ef7a6ce01e883569a177c0969bc29c69
2017-07-05new loplugin unnecessaryparenNoel Grandin1-1/+1
Change-Id: Ic883a07b30069ca6342d7521c8ad890f4326f0ec Reviewed-on: https://gerrit.libreoffice.org/39549 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-03loplugin:oncevar (clang-cl): canvasStephan Bergmann1-4/+2
Change-Id: I0fde86dbaa4bfa9377445800db176a82211aad17
2017-07-02loplugin:casttovoid: canvasStephan Bergmann4-51/+18
Change-Id: I2b719ff5fc03a74ba0f657351343462aaa9c7296
2017-06-23simplify some string handling in tracing callsNoel Grandin1-6/+2
Change-Id: I0fb76562429e691400a02216019c7f96791cf9b3 Reviewed-on: https://gerrit.libreoffice.org/39159 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-06-20loplugin:oncevar chart2Noel Grandin1-31/+24
Change-Id: I2dd0939db440b5357225395e88680dd0b0fdbf43 Reviewed-on: https://gerrit.libreoffice.org/38970 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-06-18remove unused osl/mutex.hxx includesJochen Nitschke6-6/+0
Change-Id: I3b50e45fdb99e9cd8bfda07356ee3ddb4dd0f8bb Reviewed-on: https://gerrit.libreoffice.org/38905 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>
2017-06-16configure: remove --enable-directxMichael Stahl1-1/+1
This used to require extra SDKs in days of yore but now just always build those libraries on WNT. Change-Id: I92c0a35917df42e136c022c762f0333f657a9ec6
2017-06-02loplugin:redundantcast (clang-cl)Stephan Bergmann1-2/+2
Change-Id: Ic61ed0cb1d64b27abe0007e28c7b261de3ab7114
2017-05-23loplugin:comparisonwithconstant in chart2Noel Grandin1-1/+1
Change-Id: I95787007b26cdcf0d5d1617ecd0e55d377b551d7 Reviewed-on: https://gerrit.libreoffice.org/37941 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-05-19loplugin:unusedfieldsNoel Grandin10-30/+10
make it a little smarter in dealing with fields that are smart pointers Change-Id: I44072105170882dc29fb19558f1065cffc7e5f11 Reviewed-on: https://gerrit.libreoffice.org/37751 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-05-18Revert "Fix typos"Stephan Bergmann1-1/+1
This reverts commit 26a67002fcb9381b54de6cae1aaa37120d49066a. "Iff" is not a typo, see 2a65bf32ec270484dcea4d22d3c93552dc0c24dd "Revert 'Typo: iff->if'".
2017-05-18Fix typosAndrea Gelmini1-1/+1
Only replaced "iff" with "if" Change-Id: Ib9dfa5c12b05500043147fe3b65f923b1b12a581 Reviewed-on: https://gerrit.libreoffice.org/37782 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com>
2017-05-16loplugin:checkunusedparams variousNoel Grandin1-1/+1
Change-Id: I5d1cc807134230d86e0226a12fada204004312d3 Reviewed-on: https://gerrit.libreoffice.org/37675 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-05-09cleanup osl/diagnose.h includesJochen Nitschke1-1/+0
with command > git grep -l osl/diagnose.h *.cxx | xargs grep -L -w 'OSL_\w*' | xargs sed -i '/#include *\(<\|\"\)osl\/diagnose.h\(>\|\"\).*/d' headers need more work Change-Id: I906519ebbd47a04703b4fa5943b2f7abea7a97ab Reviewed-on: https://gerrit.libreoffice.org/37350 Tested-by: Jochen Nitschke <j.nitschke+logerrit@ok.de> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2017-05-07revert OSL_ASSERT changesChris Sherlock2-2/+2
Change-Id: I365d140446bd2a62cf8256acbfdd53fe72987380
2017-05-07tdf#43157: convert most of canvas codebase away from OSL_ASSERT to assertChris Sherlock2-2/+2
Change-Id: Ie6a5942dcac62a0bc3b589ff0b82922b313f88a8
2017-04-21gbuild: Remove MSVC 2013 legacy codeDavid Ostrovsky8-8/+0
Uwinapi is discontinued. Change-Id: I063b4d0d8fab2d60de168e960a63b8181158ac01 Reviewed-on: https://gerrit.libreoffice.org/23198 Reviewed-by: David Ostrovsky <david@ostrovsky.org> Tested-by: David Ostrovsky <david@ostrovsky.org>