summaryrefslogtreecommitdiff
path: root/chart2/source/controller/chartapiwrapper
AgeCommit message (Collapse)Author
2022-01-21use more concrete types in chart2, ChartModelNoel Grandin
Change-Id: I6930e09ed471592d7c8b8fb16565b355b17bffc1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128731 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-21fix ChartDocumentWrapper::createInstanceNoel Grandin
which I broke in commit fe37aa64ff79abcd3aeedeb03d8d74798225a367 Date: Sat Jan 15 13:45:44 2022 +0200 use more concrete types in chart2, ChartView by copying behaviour from the wrong construction site. And then in commit c592574948b0a28bac965b508bc260aaa6c365d3 Date: Sun Jan 16 12:25:49 2022 +0200 use more concrete types in chart2, ChartView I spread the error further by using the incorrect behaviour I had introduced in the first commit in Chart2ModelContact::getChartView() Change-Id: I4b004b8893fa51b8968328b6a8b6ffde081f1269 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128705 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-19use more concrete types in chart2, InternalDataProviderNoel Grandin
Change-Id: Iee2cc56b00f0464e652a14eace2640e5d798eb5f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128629 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-19use more concrete types in chart2, BaseCoordinateSystemNoel Grandin
Change-Id: I1c246a3ea37595647ac254f492170a9e18540794 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128623 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-19use more concrete types in chart2, ChartTypeTemplateNoel Grandin
and return data using a little struct rather than std::pair, to make the call sites read a little better. Change-Id: Ieb6fc24e053f50823789167ed0112aa04a083725 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128613 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-19use more concrete types in chart2, DiagramNoel Grandin
Change-Id: I870f6d9fa4c0b51cf7c887199079fdbabbca1fec Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128597 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-19use more concrete types in chart2, ChartModelNoel Grandin
Change-Id: I6fea07e7b9684b5333c908dbb353aeda58dd73a2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128583 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-18use more concrete types in chart2, ChartTypeTemplateNoel Grandin
Change-Id: Ife0be0fde2f8d273411cbdbbafa2173ac80f80f7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128560 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-18use more concrete types in chart2, ChartTypeManagerNoel Grandin
Change-Id: If5055256c3e3a20ab1a30e9c8bf46f453785e80c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128557 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-16use more concrete types in chart2, ChartViewNoel Grandin
Change-Id: I51d503cd71ef2adc0e590ef836dabf9906495bbc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128475 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-16use more concrete types in chart2, DiagramNoel Grandin
Change-Id: Iae84e16b3406f4c08139764a1838e38b13cebee7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128471 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-15use more concrete types in chart2, ChartModelNoel Grandin
Change-Id: Iecbc92aa096ede1845936faa708d1a9e8747b658 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128467 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-15use more concrete types in chart2, ChartViewNoel Grandin
Change-Id: I7316d01d08eb1d9d482937fdd87bd34e2ae7e3c6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128461 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-01-13Recheck modules [a-c]* with IWYUGabor Kelemen
See tdf#42949 for motivation Change-Id: I74a3c3a67c3639376e2251c3eb917fa4139dfbd0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127808 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-01-02use concrete types in chart2, SvxDrawPageNoel Grandin
Change-Id: I0bdaa74595c0201a04490e293619c2c399ab03bd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127838 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-12-19use more cppu::BaseMutexNoel Grandin
Change-Id: Ib9da716de0addc70ca58d9085ff351c2ff8c706f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127083 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-27use more OInterfaceContainerHelper3 in chart2Noel Grandin
Change-Id: Icff667a11f1798e29c732c13b5739a4f7b581999 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125921 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-10-29Prepare for removal of non-const operator[] from Sequence in chart2Mike Kaganski
Change-Id: I71e0b458c4dd2a85e36a485e3efa72b1077b0e54 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124346 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-09-15Use <comphelper/servicehelper.hxx> implementing XUnoTunnel part 5Mike Kaganski
- Revise uses of getSomething to use getFromUnoTunnel Where that is impossible, use getSomething_cast to unify casting, and minimize number of places doing low-level transformations. The change keeps the existing tunnel references that last for the duration of the pointers' life, because sometimes destroying such reference may destroy the pointed object, and result in use after free. Change-Id: I291c33223582c34cd2c763aa8aacf0ae899ca4c0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122101 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-09-15Use <comphelper/servicehelper.hxx> implementing XUnoTunnel part 1Mike Kaganski
The header got some changes: 1. Move UnoTunnelIdInit and isUnoTunnelId into 'comphelper' namespace 2. Rename UnoTunnelIdInit to UnoIdInit, as a precondition to replace of uses of OImplementationId with it, including in XTypeProvider 3. Introduce convenience functions 'getSomething_cast' to cast between sal_Int64 and object pointers uniformly. 4. Rename getUnoTunnelImplementation to getFromUnoTunnel, both to make it a bit shorter, and to reflect its function better. Templatize it to take also css::uno::Any for convenience. 5. Introduce getSomethingImpl, inspired by sw::UnoTunnelImpl; allow it handle cases both with and without fallback to parent. 6. Adjust UNO3_GETIMPLEMENTATION_* macros TODO (in separate commits): - Drop sw::UnoTunnelImpl and sw::UnoTunnelGetImplementation - Replace all uses of OImplementationId in core with UnoIdInit - Deprecate OImplementationId in <cppuhelper/typeprovider.hxx> - Change implementations of getSomething to use getSomethingImpl - Revise uses of getSomething to use getFromUnoTunnel Change-Id: If4a3cb024130f1f552f988f0479589da1cd066e7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122022 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-08-31clang-tidy:readability-redundant-member-initNoel Grandin
Change-Id: I5e8baec88d5f17ddda452bd945c87769623cb4e1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121357 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-23loplugin:referencecasting look through more clang TypesNoel Grandin
Note that because of where the fix resides, loplugin:redundantcast also notices a few more things. Change-Id: I0b66047fadfff2c5ceafcbd3eab085de00d861a6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120865 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-11convert some LogicToLogic calls to use o3tl::convert insteadTomaž Vajngerl
If a LogicToLogic uses fixed units, we can use o3tl::convert instead. We can also do the same for all other cases where LogicToLogic is used, but that needs additional investigation to determine if it is safe to do so. Note: MapUnit::Pixel is converted to o3tl::Length::pt because it assumed 72 PPI for a logical pixel, which corresponds with the conversion rate of a point (72 PPI). Today, 96 PPI is standard, which is also used for o3tl::Length:px. Change-Id: I29126df38bfcfda74b5d83d4cb880a378aecd18b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120230 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2021-06-30Purge out rtl::math::setNanBaiXiaochun
Change-Id: If8794c105e279afd4437517d3e61f2f900eb6490 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118123 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-03-25const OUString -> const OUStringLiteralMike Kaganski
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-02-08tdf#94235 Add support for series name in data series labelsSamuel Mehrbrodt
including ODF/OOXML import/export (and test) Change-Id: Id5a5194630a67476f7c5390294400a00ea3ad42d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110338 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
2021-01-09fix coverity parse errorsCaolán McNamara
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-26New loplugin:stringliteralvarStephan Bergmann
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-11-22tdf#123936 Formatting files in module chart2 with clang-formatPhilipp Hofer
Change-Id: Ie4dea73190040e5716fe531cf35fae20d7e175db Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105650 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2020-11-06tdf#42949 Fix new IWYU warnings in directories c*Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Iac1e7802dbe1efa01c2befdd10406231788d4fc1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105315 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-10-21use tools::Long in basegfx..chart2Noel
Change-Id: Ide4014348d51f0b5f59e1e91b8d41c7748853254 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104608 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-09-28Fix typo in codeAndrea Gelmini
Change-Id: Ifab76c880b1802740689704f929858b261e1f5bd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103488 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-09-20cid#1466912 silence Unchecked return valueCaolán McNamara
Change-Id: I5d8ef4a52f0aeef9012445a382aa472bd69ec925 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103069 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-09-16Turn OUStringLiteral into a consteval'ed, static-refcound rtl_uStringStephan Bergmann
...from which an OUString can cheaply be instantiated. This is the OUString equivalent of 4b9e440c51be3e40326bc90c33ae69885bfb51e4 "Turn OStringLiteral into a consteval'ed, static-refcound rtl_String". Most remarks about that commit apply here too (this commit is just substantially bigger and a bit more complicated because there were so much more uses of OUStringLiteral than of OStringLiteral): The one downside is that OUStringLiteral now needs to be a template abstracting over the string length. But any uses for which that is a problem (e.g., as the element type of a container that would no longer be homogeneous, or in the signature of a function that shall not be turned into a template for one reason or another) can be replaced with std::u16string_view, without loss of efficiency compared to the original OUStringLiteral, and without loss of expressivity. The new OUStringLiteral ctor code would probably not be very efficient if it were ever executed at runtime, but it is intended to be only executed at compile time. Where available, C++20 "consteval" is used to statically ensure that. The intended use of the new OUStringLiteral is in all cases where an object that shall itself not be an OUString (e.g., because it shall be a global static variable for which the OUString ctor/dtor would be detrimental at library load/unload) must be converted to an OUString instance in at least one place. Other string literal abstractions could use std::u16string_view (or just plain char16_t const[N]), but interestingly OUStringLiteral might be more efficient than constexpr std::u16string_view even for such cases, as it should not need any relocations at library load time. For now, no existing uses of OUStringLiteral have been changed to some other abstraction (unless technically necessary as discussed above), and no additional places that would benefit from OUStringLiteral have been changed to use it. Global constexpr OUStringLiteral variables defined in an included file would be somewhat suboptimal, as each translation unit that uses them would create its own, unshared instance. The envisioned solution is to turn them into static data members of some class (and there may be a loplugin coming to find and fix affected places). Another approach that has been taken here in a few cases where such variables were only used in one .cxx anyway is to move their definitions from the .hxx into that one .cxx (in turn causing some files to become empty and get removed completely)---which also silenced some GCC -Werror=unused-variable if a variable from a .hxx was not used in some .cxx including it. To keep individual commits reasonably manageable, some consumers of OUStringLiteral in rtl/ustrbuf.hxx and rtl/ustring.hxx are left in a somewhat odd state for now, where they don't take advantage of OUStringLiteral's equivalence to rtl_uString, but just keep extracting its contents and copy it elsewhere. In follow-up commits, those consumers should be changed appropriately, making them treat OUStringLiteral like an rtl_uString or dropping the OUStringLiteral overload in favor of an existing (and cheap to use now) OUString overload, etc. In a similar vein, comparison operators between OUString and std::u16string_view have been added to the existing plethora of comparison operator overloads. It would be nice to eventually consolidate them, esp. with the overloads taking OUStringLiteral and/or char16_t const[N] string literals, but that appears tricky to get right without introducing new ambiguities. Also, a handful of places across the code base use comparisons between OUString and OUStringNumber, which are now ambiguous (converting the OUStringNumber to either OUString or std::u16string_view). For simplicity, those few places have manually been fixed for now by adding explicit conversion to std::u16string_view. Also some compilerplugins code needed to be adapted, and some of the compilerplugins/test cases have become irrelevant (and have been removed), as the tested code would no longer compile in the first place. sal/qa/rtl/strings/test_oustring_concat.cxx documents a workaround for GCC bug <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96878> "Failed class template argument deduction in unevaluated, parenthesized context". That place, as well as uses of OUStringLiteral in extensions/source/abpilot/fieldmappingimpl.cxx and i18npool/source/localedata/localedata.cxx, which have been replaced with OUString::Concat (and which is arguably a better choice, anyway), also caused failures with at least Clang 5.0.2 (but would not have caused failures with at least recent Clang 12 trunk, so appear to be bugs in Clang that have meanwhile been fixed). Change-Id: I34174462a28f2000cfeb2d219ffd533a767920b8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102222 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-09-04tdf#124176 Use #pragma once in chart2George Bateman
This commit was carried out mostly by a Python script, source of which is at https://bugs.documentfoundation.org/show_bug.cgi?id=124176#c97. Change-Id: Ifee23b494264f895e5612952d0875cac064e4132 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100181 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2020-09-02tdf#136061 Chart ODF/OOXML: fix missing custom labelsBalazs Varga
by UNO extensions ShowCustomLabel in DataPointLabel.idl and CUSTOM in ChartDataCaption.idl, fixing OOXML/ODF import/export. We should display custom data label even if DataPointLabel is disabled (e.g. category name and/or value fields are not displayed). Note: import of the embedded chart of the DOCX unit test document uses also ODF format in the background, testing also the extension of the native file format. Change-Id: I73e21f1e69fddec9f3b4163c46b6582cd1c74b5d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101640 Tested-by: Jenkins Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2020-08-31tdf#134571 chart2, xmloff: add loext:custom-leader-linesBalazs Varga
new ODF chart series style attribute for saving not default (switched off) state of data labels in custom positions. Note: import of the embedded chart of the DOCX unit test document uses also ODF format in the background, testing also this loext attribute, i.e. the chart of the unit test document doesn't contain custom leader lines. Change-Id: Ia6b76e8d7fe5b6b6204761f3bbc2309f1b631008 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101442 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2020-08-28Change OUStringLiteral from char[] to char16_t[]Stephan Bergmann
This is a prerequisite for making conversion from OUStringLiteral to OUString more efficient at least for C++20 (by replacing its internals with a constexpr- generated sal_uString-compatible layout with a SAL_STRING_STATIC_FLAG refCount, conditionally for C++20 for now). For a configure-wise bare-bones build on Linux, size reported by `du -bs instdir` grew by 118792 bytes from 1155636636 to 1155755428. In most places just a u"..." string literal prefix had to be added. In some places char const a[] = "..."; variables have been changed to char16_t, and a few places required even further changes to code (which prompted the addition of include/o3tl/string_view.hxx helper function o3tl::equalsIgnoreAsciiCase and the additional OUString::createFromAscii overload). For all uses of macros expanding to string literals, the relevant uses have been rewritten as u"" MACRO instead of changing the macro definitions. It should be possible to change at least some of those macro definitions (and drop the u"" from their call sites) in follow-up commits. Change-Id: Iec4ef1a057d412d22443312d40c6a8a290dc6144 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101483 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-08-06tdf#135184 add linecaps in chartsRegina Henschel
Chart is currently not able to interpret property linecap. But in case of linecap 'round' or 'square', line dashes lengths are adapted so that they look same as in MS Office (tdf#134053). This does not work, if the corresponding linecap property is not interpreted. Dashed border of data labels is not fixed because of bug tdf#135366. In addition I have fixed errors in prstDash detection, which I have noticed while creating unit tests. The unit tests cover file text, not visual appearence. Change-Id: I8cf2d2b2fc0923c2882f8148b4550bc363270480 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99562 Tested-by: Jenkins Reviewed-by: Regina Henschel <rb.henschel@t-online.de>
2020-07-16compact namespace: chart2Noel Grandin
Change-Id: I3c9f42b2fc40d65e573a668ed7c4eb88dc64d22b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98904 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-06-30Related: tdf#131175 OOXML chart: import data label fill patternGülşah Köse
Change-Id: I2db64489c86e4381167eb13af4ab5118113960d5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93715 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-05-26Fix loplugin:simplifypointertobool for libstdc++ std::shared_ptrStephan Bergmann
...where the get member function is defined on a std::__shared_ptr base class, so loplugin:simplifypointertobool used to miss those until now. (While e.g. using libc++ on macOS found those cases.) 366d08f2f6d4de922f6099c62bb81b49d89e0a68 "new loplugin:simplifypointertobool" was mistaken in breaking isSmartPointerType(const clang::Type* t) out of isSmartPointerType(const Expr* e); c874294ad9fb178df47c66875bfbdec466e39763 "Fix detection of std::unique_ptr/shared_ptr in loplugin:redundantpointerops" had introduced that indivisible two-step algorithm on purpose. The amount of additional hits (on Linux) apparently asked for turning loplugin:simplifypointertobool into a rewriting plugin. Which in turn showed that the naive adivce to just "drop the get()" is not sufficient in places that are not contextually converted to bool, as those places need to be wrapped in a bool(...) functional cast now. If the expression was already wrapped in parentheses, those could be reused as part of the functional cast, but implementing that showed that such cases are not yet found at all by the existing loplugin:simplifypointertobool. Lets leave that TODO for another commit. Besides the changes to compilerplugins/ itself, this change has been generated fully automatically with the rewriting plugin on Linux. Change-Id: I83107d6f634fc9ac232986f49044d7017df83e2a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/94888 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Jenkins
2020-05-18use for-range on Sequence in chart2Noel Grandin
Change-Id: Ief02e5d5284b0cbad26b04c0a282dccfee577b90 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/94398 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-05-08compact namespace in canvas..cuiNoel Grandin
Change-Id: I7bd0c2a55b936896fcfe7e1a374871008a18618f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93706 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-05-04tdf#131175 Import data label solid fill and color.Gülşah Köse
Change-Id: I8a3ef6e60d4f2a13310bb9a8fc4eb873df3f9b4f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93407 Tested-by: Jenkins Reviewed-by: Gülşah Köse <gulsah.kose@collabora.com>
2020-04-27Make upcasting css::uno::Reference ctor require complete typesStephan Bergmann
The main reason for the "home-grown" UpCast introduced with 904b3d1fceee5827076758ed2a81f80cb73493ca "Up-cast conversion constructor for css::uno::Reference" in 2013 was probably that we could not yet rely on C++11 std::is_base_of back then. A (welcome) side effect was that the derived class could be incomplete. However, specializations of UpCast relying on whether or not T2 is incomplete are obviously an ODR violation if the type is incomplete in some TUs and complete (and derived from T1) in others. And even if UpCast had internal linkage, it would still be brittle that its behavior depends on the completeness of T2 at the point of the template's instantiation, and not necessarily at the point of use. That means we should better base that ctor on std::is_base_of (which we can do now since 39a1edd6fec902ef378acce8af42c4d7fba280d0 "Make css::uno::Reference upcast ctor LIBO_INTERNAL_ONLY"), which causes a compilation error at least on Clang and GCC if the completeness requirements are not met. This change fixes all the cases where types need to be complete now, plus any resulting loplugin:referencecasting warnings ("the source reference is already a subtype of the destination reference"). Change-Id: Ieb9e3552e90adbf2c5a5af933dcb872e20661a2f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92950 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-04-19loplugin:flatten in chart2Noel Grandin
Change-Id: Iadc4da6515a7d82e7a92b33d74d589b61fa2c64f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92480 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-04-17tdf#131979 Chart ODF import-export of Link to source formatBalazs Varga
setting also into data point styles, fixing lost numbering style of custom data points. (Only export into the data series style was supported previously.) Also fix tdf#131115 - FILEOPEN: Incorrect format of single data label Regression from commit: e57d90cd4e51a1353eafc87bb29cfe6076704a7c (tdf#129173 tdf#129175 Fix number format of data labels) Data point styles in older ODF files do not contain the 'link-data-style-to-source' property, so they used the data series style property during the import previously. Now we set the default false value, if the data point style contains a 'data-style-name' (number format). Change-Id: I4786e62ca75770ed632463bcf1275ece7ea793f4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91967 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2020-04-14loplugin:buriedassign in c*Noel Grandin
Change-Id: Id14fed7e5c0f588ad3c927f12251432d12c1a7c8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92190 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-04-09tdf#127792 implement UNO chart attribute MajorOriginTünde Tóth
based on the specification in OFFICE-3936 for ODF 1.4: https://issues.oasis-open.org/browse/OFFICE-3936 Note: import of the embedded chart of the DOCX unit test document uses also ODF format in the background, testing also the extension of the native file format. Follow-up of commit 830e539547c463b932ce643517f880789185032d (tdf#127393 OOXML chart import: fix X axis position setting "CrossBetween"). See also commits with "ShiftedCategoryPosition" in their descriptions. Change-Id: I9cd278ac0172c0fab7c51d585a65c34a0ad60b82 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90081 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>