summaryrefslogtreecommitdiff
path: root/forms
AgeCommit message (Collapse)AuthorFilesLines
2021-05-06loplugin:unusedmethodsNoel Grandin1-1/+0
plugin code needed some updating because it was interacting badly with PCH code in pluginhandler::ignoreLocation Change-Id: I228f94a4e285747bd1d5b8536010f8617118cafa Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115212 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-02throw() -> noexcept, part 2/3: Automatic loplugin:noexcept rewriteStephan Bergmann7-8/+8
Change-Id: I076f16d0536b534abf0ced4d76051eadb4c0e033 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114949 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-04-29loplugin:stringadd simplify some *StringBuffer operationsNoel Grandin1-6/+6
pulled from a larger patch which I created with a more permissive variant of this plugin Change-Id: I7abf1f3f09e84703b6e0e52fe9587dff691b2187 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114875 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-04-27loplugin:stringadd convert chained append to +Noel Grandin1-1/+1
which can use the more efficient *StringConcat Also fix a crash in stringview plugin which started happening while I working on this. Change-Id: I91a5b9b7707d1594d27d80b73930f5afac8ae608 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114568 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-04-26drop mask from BitmapExNoel Grandin1-1/+1
So that we have fewer cases to deal with when we transition to 32-bit bitmaps. (*) rename maMask to maAlphaMask, since now it is only being used for alpha duties. (*) drop mbAlpha and mbTransparent to simplify state management, the only thing we need to check for alpha is if maAlphaMask is non-empty. Change-Id: I06252e38e950e846a94b4c2ba8ea763be17801fe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111679 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-04-22no need makeStringAndClear() when appending to bufferNoel Grandin1-1/+1
it just creates an unnecessary temporary Change-Id: Ide3cd99b2ac4f2a621e5d55ce4bdc95d05430709 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114467 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-04-08update PCHsLuboš Luňák1-1/+3
Change-Id: Ia9d04447f927e270a55500e7f35723a729bc01dd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113801 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2021-04-07Updated README.md files to represent current code / use Markdown formatHossein1-1/+3
Previously, all of the README files have been renamed to README.md and now, the contents of these files were changed to use Markdown format. Other than format inconsistency, some README.md files lacked information about modules, or were out of date. By using LibreOffice / OpenOffice wiki and other documentation websites, these files were updated. Now every README.md file has a title, and some description. The top-level README.md file is changed to add links to the modules. The result of processing the Markdown format README.md files can be seen at: https://docs.libreoffice.org/ Change-Id: Ic3b0c3c064a2498d6a435253b041df010cd7797a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113424 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de> Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2021-04-07rtl::Static -> function local staticNoel Grandin1-6/+2
Change-Id: I2071c27bdf074403ec24e67f9278ac27f9491303 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113698 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-03-28drop operator bool and operator! from Bitmap and BitmapExNoel1-1/+1
IRC chat: <quikee[m]> noelgrandin: doesn't adding operator bool to Bitmap has the same problem as Graphic and the reason why you dropped that commit 7334034ae93b49fc93b5859a3c047a319d138282 "drop Graphic::operator bool" <noelgrandin> quikee[m], hmmm, good point <noelgrandin> maybe I should just drop both operator bool and operator! in favor of IsEmpty <quikee[m]> noelgrandin: I don't remember what the problem is I just remembered we dropped it Graphic :) sure, dropping everything for IsEmpty is probably the best Change-Id: Ieae289cda64f0b8d8fdecd5ea9e6f2bb874ff4cd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113163 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-03-25const OUString -> const OUStringLiteralMike Kaganski1-2/+2
Mostly automated rewrite Change-Id: Ie020a083f898bc126b8fb039d4ecb2e687172da1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112965 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-03-24Using .md extension/Markdown syntax for modules READMEHossein1-0/+0
Renaming all README files for all top level modules to README.md, applying no content change at this stage to be able to track history of the files. These files should be edited to use correct Markdown syntax later. Change-Id: I542fa3f3d32072156f16eaad2211a397cc212665 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112977 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2021-03-23tdf#124176 Use pragma once in f*Vincent LE GARREC94-371/+94
filter, forms, fpicker, framework Change-Id: I55a25ad2dc3749e63465e638e8eeea3c322eabbf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112047 Tested-by: Jenkins Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
2021-03-13add PixelFormat enum that replaces bit count in Bitmap/BitmapExTomaž Vajngerl1-1/+1
Bit count for the image is a numeric value (sal_uInt16) but only a handful of values make sense - namely 1,4,8,24 and 32. This replaces the numeric value with an enum, which only accepts those values and checks the correct values are used at compile time. Change-Id: I0fc137c62bce3b0d021f05019a1648da628521bc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112408 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2021-03-11use strong_int for item ids in vcl::ToolBoxNoel1-30/+31
(*) fix bug in SfxToolBoxControl::StateChanged where it was using the slot id instead of the toolbox item id (*) I left the logic in SbaTableQueryBrowser alone, but it looks suspicious, casting slot ids to toolbox ids Change-Id: Ied229164c27fb4456b0515c6fdcbd1682766a1a9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112186 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-03-09Make sal/config.h the first in pchMike Kaganski1-2/+2
By convention, it should be the first include in C/CXX files; so use of pch should not break that. Change-Id: Ic329c5f39e8f48ad1778724368e262e48972342b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112123 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-02-26loplugin:refcounting in formsNoel5-14/+15
Change-Id: Idba46c8b30a3c44f12c0aaa8a00477865ecfb848 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111542 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-02-21loplugin:refcounting in formsNoel18-61/+41
Change-Id: I19d67e54f77e354eaddaaa7de1f3e22c2b7cdbf6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111280 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-02-16loplugin:referencecasting in editeng..frameworkNoel7-18/+17
Change-Id: Ia3375011ecd0a65afed0f131f477fc1542603fde Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110948 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-02-09loplugin:referencecasting check for Reference::queryNoel1-1/+1
Change-Id: I008d16d933c70df132699872ac4c39a5c1f87b34 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110592 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-02-04tdf#140151: revert fix for tdf#46579 which caused regressionJulien Nabet1-2/+2
Change-Id: I48468d4cef1f4d68dab4759c8da30aead6b99e5d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110425 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-01-28simplify code, use more subView()Noel1-1/+1
Change-Id: I569c7f34acbdf8451cd5c9acf1abd334637072d1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110051 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-01-25avoid some ref-countingNoel Grandin2-2/+2
can just return a pointer here, instead of VclPtr. Change-Id: I9ab8962cbbe84ed4dfcfd658a6d758112914cb89 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109923 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-01-24Use ContainerType().swap and avoid local variablesMike Kaganski2-4/+2
Change-Id: I773555180758a97aff37f9bc27de83c355d71521 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109761 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-01-16make the Color constructors explicitly specify transparencyNoel2-3/+3
to reduce the churn, we leave the existing constructor in place, and add a clang plugin to detect when the value passed to the existing constructor may contain transparency/alpha data. i.e. we leave expressions like Color(0xffffff) alone, but warn about any non-constant expression, and any expression like Color(0xff000000) Change-Id: Id2ce58e08882d9b7bd0b9f88eca97359dcdbcc8c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109362 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-01-10static_cast after dynamic_castNoel Grandin1-2/+2
Change-Id: I3792ddadad9582a7e6f4740829c081d9571ddaff Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109049 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-01-09fix coverity parse errorsCaolán McNamara2-3/+3
Change-Id: I3a1179947704452e3ffec02be59d0f7bf0b75ab0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109017 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-12-30AppendRowSetValueString is used on a ValueListStephan Bergmann1-1/+1
(aka a vector<ORowSetValue>, so make it work on ORowSetValue. (This will avoid a bogus warning when extending loplugin:stringviewparam to operator +=.) Change-Id: I2c4bbb2f6b4c920f26038053f9c5d4607e8c3378 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108454 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-29loplugin:stringviewparam: operator +Stephan Bergmann3-14/+15
Change-Id: I044dd21b63d7eb03224675584fa143009c6b6008 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108418 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-26tdf#88205: Adapt uses of css::uno::Sequence to use initializer_list ctorBayram Çiçek2-2/+2
Change-Id: Id4034a57580f37fd71f841deec9edfe9b7c26a67 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108286 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2020-12-26New loplugin:stringliteralvarStephan Bergmann2-3/+3
See the comment at the top of compilerplugins/clang/stringliteralvar.cxx for details. (Turned some affected variables in included files into inline variables, to avoid GCC warnings about unused variables.) Change-Id: Ie77219e6adfdaaceaa8b4e590b08971f2f04c83a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108239 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-25Typos in code (vlc->vcl/vclx)Julien Nabet2-2/+2
Change-Id: I3c0f0f7a2129ca49c18d3a65aef74061e895853c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108284 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2020-12-24vcl: move access functions into appropriate bitmap access filesChris Sherlock1-1/+1
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-11Adapt the remaining OUString functions to std string_viewStephan Bergmann4-5/+14
...for LIBO_INTERNAL_ONLY. These had been missed by 1b43cceaea2084a0489db68cd0113508f34b6643 "Make many OUString functions take std::u16string_view parameters" because they did not match the multi-overload pattern that was addressed there, but they nevertheless benefit from being changed just as well (witness e.g. the various resulting changes from copy() to subView()). This showed a conversion from OStringChar to std::string_view to be missing (while the corresponding conversion form OUStringChar to std::u16string_view was already present). The improvement to loplugin:stringadd became necessary to fix > [CPT] compilerplugins/clang/test/stringadd.cxx > error: 'error' diagnostics expected but not seen: > File ~/lo/core/compilerplugins/clang/test/stringadd.cxx Line 43 (directive at ~/lo/core/compilerplugins/clang/test/stringadd.cxx:42): simplify by merging with the preceding assignment [loplugin:stringadd] > File ~/lo/core/compilerplugins/clang/test/stringadd.cxx Line 61 (directive at ~/lo/core/compilerplugins/clang/test/stringadd.cxx:60): simplify by merging with the preceding assignment [loplugin:stringadd] > 2 errors generated. Change-Id: Ie40de0616a66e60e289c1af0ca60aed6f9ecc279 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107602 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-04update pchesCaolán McNamara1-2/+7
Change-Id: I3e22c2000da03f6f3345353846213203993aa865 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107192 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-12-03Simplify code in forms/clickableimageJulien Nabet1-1/+1
following 07be45d03f80fa681c697ca9f5a13084a81c7a26 tdf#46579: fix form fields 'Image Button' in Forms urls have this form: .uno:FormController/moveToFirst .uno:FormController/moveToPrev etc. So we must use these links for hyperlinks + interceptor with ControlFeatureInterception Change-Id: I2cbbfeac9ed65420f11f21a30e1a1f7cb2d70850 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107158 Tested-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2020-12-02tdf#46579: fix form fields 'Image Button' in FormsJulien Nabet1-2/+2
urls have this form: .uno:FormController/moveToFirst .uno:FormController/moveToPrev etc. So we must use these links for hyperlinks + interceptor with ControlFeatureInterception Change-Id: I9cff19833d859624239ca6c76152cc88f9cbb278 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107037 Tested-by: Jenkins Reviewed-by: Lionel Mamane <lionel@mamane.lu> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2020-12-02Removed triplicated includesAndrea Gelmini2-3/+0
Change-Id: I91af264306ac7a61c90bf46df0560448b7d2285d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106981 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2020-12-01OSL_FAIL.*exception -> TOOLS_WARN_EXCEPTIONNoel11-13/+22
Change-Id: I6800e23ead2767d245d5da71d2d40e0f8a6d7e1f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106859 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-11-30loplugin:stringviewparam include comparisons with string literalsNoel1-2/+2
Change-Id: I8ba1214500dddaf413c506a4b82f43d63cda804b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106559 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-11-24loplugin:stringviewparam extend to comparison operatorsNoel4-9/+9
which means that some call sites have to change to use unicode string literals i.e. u"foo" instead of "foo" Change-Id: Ie51c3adf56d343dd1d1710777f9d2a43ee66221c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106125 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-11-19loplugin:stringview: Flag empty string converted to string viewStephan Bergmann1-3/+3
Change-Id: Idf412dc5f235230512160cb4fb7e1a00baa1cfa7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106085 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-11-13tdf#123936 Formatting files in module forms with clang-formatPhilipp Hofer13-100/+75
Change-Id: I230375bd002147642db37728fa0287b6a554e330 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105670 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2020-11-12New loplugin:stringviewparamStephan Bergmann2-12/+16
...to "Find functions that take rtl::O[U]String parameters that can be generalized to take std::[u16]string_view instead." (Which in turn can avoid costly O[U]String constructions, see e.g. loplugin:stringview and subView.) Some of those functions' call sites, passing plain char string literals, needed to be adapted when converting them. Change-Id: I644ab546d7a0ce9e470ab9b3196e3e60d1e812bc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105622 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-11-12tdf#42949 Fix new IWYU warnings in directories [e-f]*Gabor Kelemen4-4/+9
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-11-02toolbox always has flat styleNoel Grandin1-1/+0
ever since commit c1cd6af623e86b5b1b45f9d09dc17d6fbb907f02 Author: Jens-Heiner Rechtien <hr@openoffice.org> Date: Mon May 10 14:51:02 2004 +0000 INTEGRATION: CWS nwf (1.64.66); FILE MERGED 2004/03/31 09:28:33 ssa 1.64.66.1: #i25130# force flat toolbox buttons except for a completely and utterly undocumented hack of a registry key, introduced in commit 736dc0956a50315ec72ad126406556657a750d37 Author: Rüdiger Timm <rt@openoffice.org> Date: Thu Apr 17 14:19:46 2003 +0000 INTEGRATION: CWS vcl08 (1.57.2.4.18); FILE MERGED 2003/04/14 17:46:27 ssa 1.57.2.4.18.1: #108699# disabled flat toolbox buttons not exported anymore which only seems to apply to Windows. So just remove this. Change-Id: Idf315b8c89c3119883a5e6880d003d379fe6faec Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105155 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-10-22long->tools::Long in forms..frameworkNoel3-25/+26
Change-Id: I4cb29aade5ad1d3c3588b9437197e8493292872e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104625 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-10-03use more TOOLS_WARN_EXCEPTIONNoel1-2/+1
Change-Id: I8b5cde993c13e0b7c8c830b1ff698933a6b7cfd0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103863 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-09-26Fix typo in codeAndrea Gelmini1-3/+3
It passed "make check" on Linux Change-Id: I823a0ae998addb620b490b649e1369106f8f4e8e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103462 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2020-09-25fix compile error in java test codeNoel Grandin1-1/+1
likely caused by commit 89340fcb6509afd1bffea7b6060d5ff5a444b3f1 Author: Noel Grandin <noel.grandin@collabora.co.uk> Date: Wed May 20 13:45:07 2020 +0200 use for-range on Sequence in f* but since this code appears to be currently unused, was never caught Change-Id: I0e2f8eade9376ccd18ad9a63e6d5e3012a659938 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103381 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>