49 Commits
Author SHA1 Message Date
Jason Whitmore a73823a4c1 chart2: Add unit tests for CalculateBSplines
Change-Id: I46af0b5c72ef96c42ea0eb60a5c8b6383a556cdf
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/208265
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-09 09:33:05 +02:00
Dennis Francis 84129dd550 chart2: draw the correlation circle plot
Each series gives one arrow, from the origin to the point whose

1. x-coordinate value is the correlation of that series' feature column
   with the first dimension column.
2. y-coordinate value is the correlation of that series' feature column
   with the second dimension column.

A symbol marks the tip and the feature name sits beside it. The circle
of radius one and the two lines through the origin are drawn behind the
arrows, and both axes are held at minus one to one on a square plot
area, so a length in the picture means the same in both directions and
the circle stays round.

The correlations are worked out while the shapes are made rather than kept
anywhere, so they follow the cells they come from. Working them out needs the
whole of the three columns.

The correlation coefficient code itself is in a small header of its own
with a test beside it. It leaves out the instances where either side is
missing, and it has no answer for a feature that does not vary or for
fewer than two instances. A feature without an answer gets no arrow,
as there is no direction to point in.

Error bars, trend lines and area properties are turned off for this chart
type, since a point stands for a worked out pair rather than for a value in a
cell, and symbols are turned on because the tip of each arrow carries one. The
arrows take the line colour and width of their series, and the template asks
for thin ones, which is what keeps a crowd of them apart. The legend hands out
the same symbol as the arrow tip, so a key can be matched to an arrow.

Grids are turned off by default for this chart as the user is more
interested in the direction/angles and the magnitude of the "rays" from
the origin.

Change-Id: I2d8b3aa6ef7d66bd9deb1f63a647767a1b62ac90
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/8103
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Tested-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
(cherry picked from commit e096bfee9c85a22e8b8155944a63ee9d6f72f75a)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/210465
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-03 19:32:19 +02:00
Noel Grandin 1bd04a5413 [API CHANGE] remove XPivotTableDataProvider
in favor of a regular C++ interface class, since this is purely used internally to LO

Change-Id: I84991efb1b0c8829e2175dc083b0f8627fcb1712
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194512
Code-Style: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2025-11-26 10:06:23 +01:00
Noel Grandin e09f212f91 merge chartcore and chartcontroller libraries
there is no good reason to keep these separate

Change-Id: Ib484dbd5d331b0d1a117f5fc2e331123c4e70d82
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/183478
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2025-03-29 18:53:26 +01:00
Xisco Fauli 6e9b99ffe0 tdf#120348: move UItest to CppUnittest
for that, create a new CppunitTest_chart2_uichart
in chart2

Change-Id: Ie4cdaff4a1dd623c7788ed7acdd5ef135f403e84
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/143305
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2022-11-25 21:28:10 +01:00
Noel Grandin 4e17fc21bf split chart2 export unit test
since it was running for quite a while compared to the others

Change-Id: Ia83a452fea67de425691f8ef66f23cde47fc0af8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140236
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-09-20 14:38:25 +02:00
Xisco Fauli 268f0f3f0d run CppunitTest_chart2_xshape without ENABLE_CHART_TESTS
This was added in d8ae59e097
"add concept for chart xshape tests" and it's only run
when using --enable-chart-tests
OTOH, SdImportTest::testDocumentLayout in sd/qa/unit/import-tests.cxx
also uses doXMLDiff to compare shapes and it's run without any
special flag.
Let's remove the ENABLE_CHART_TESTS check to see if jenkins or any
tinderbox fails. If it does, we can always revert this commit.
If it works fine, I'll remove the --enable-chart-tests machinery
in a follow-up commit in some days

Change-Id: I5d462df09303701826e5849e9e3bacca465da814
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136796
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2022-07-04 12:41:23 +02:00
Xisco Fauli a2f42f37a0 Split CppunitTest_chart2_import into two
Change-Id: I1a9b98b9e20fd6e097bc8fd68958b7feb66991f5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117236
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-06-15 13:12:48 +02:00
Xisco Fauli 94fdd0191f Split CppunitTest_chart2_export into two
it already had 148 tests

Change-Id: I83e0055bcf1449cd48a28149a6ef0b149a1d6901
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116914
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-06-09 16:11:03 +02:00
Regina Henschel 74be8bb787 tdf#135184 add linecaps in charts
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-08-06 13:10:14 +02:00
Michael Stahl a626bdd56d gbuild: rename value OS=IOS to OS=iOS
This gets rid of the horrible hack in gbuild.mk to accomodate the
case-incorrect iOS platform makefiles that cannot be renamed without
upsetting git on file systems that sadly lack the case sensitivity
feature.

Keep the macro defined to IOS though.

Change-Id: I1022bfef4900da00e75fc1ccce786b20f8673234
Reviewed-on: https://gerrit.libreoffice.org/62705
Tested-by: Jenkins
Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Tor Lillqvist <tml@collabora.com>
2018-11-01 16:39:54 +01:00
Markus Mohrhard 026e2623f7 remove the GL based 3D charts
Change-Id: Ia578c71ae70aa0a85b49fa50138edf90f961b1e9
Reviewed-on: https://gerrit.libreoffice.org/57533
Tested-by: Jenkins
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2018-07-17 02:59:19 +02:00
Caolán McNamara 00657aef09 migrate to boost::gettext
* all .ui files go from <interface> to <interface domain="MODULE"> e.g. vcl
* all .src files go away and the english source strings folded into the .hrc as NC_("context", "source string")
* ResMgr is dropped in favour of std::locale imbued by boost::locale::generator pointed at matching
  MODULE .mo files
* UIConfig translations are folded into the module .mo, so e.g. UIConfig_cui
  goes from l10n target to normal one, so the res/lang.zips of UI files go away
* translation via Translation::get(hrc-define-key, imbued-std::locale)
* python can now be translated with its inbuilt gettext support (we keep the name strings.hrc there
  to keep finding the .hrc file uniform) so magic numbers can go away there
* java and starbasic components can be translated via the pre-existing css.resource.StringResourceWithLocation
  mechanism
* en-US res files go away, their strings are now the .hrc keys in the source code
* remaining .res files are replaced by .mo files
* in .res/.ui-lang-zip files, the old scheme missing translations of strings
  results in inserting the english original so something can be found, now the
  standard fallback of using the english original from the source key is used, so
  partial translations shrink dramatically in size
* extract .hrc strings with hrcex which backs onto
   xgettext -C --add-comments --keyword=NC_:1c,2 --from-code=UTF-8 --no-wrap
* extract .ui strings with uiex which backs onto
   xgettext --add-comments --no-wrap
* qtz for gettext translations is generated at runtime as ascii-ified crc32 of
   content + "|" + msgid
* [API CHANGE] remove deprecated binary .res resouce loader related uno apis
      com::sun::star::resource::OfficeResourceLoader
      com::sun::star::resource::XResourceBundleLoader
      com::sun::star::resource::XResourceBundle
    when translating strings via uno apis
      com.sun.star.resource.StringResourceWithLocation
    can continue to be used

Change-Id: Ia2594a2672b7301d9c3421fdf31b6cfe7f3f8d0a
2017-07-21 08:20:50 +01:00
jan Iversen 5a72018557 iOS, convert CPPUnittest to noop
unittest is not supported for iOS
due to the way it is build

Change-Id: I0682c5252231668edc2ec186147b872ef6fcc695
2017-06-23 21:40:12 +02:00
Tomaž Vajngerl 9009663deb tdf#83257 [API-CHANGE] Pivot chart implementation
This is a squashed commit of the pivot chart implementation.

Some of the changes:
- Add pivot chart specific (pivot table) data provider which
  provides the data from a pivot table to the associated chart.
- When inserting a chart and the cursor is in a pivot table,
  in that case insert a pivot chart
- Modify the pivot chart when the pivot table changes
- Collect and set the number format for the values
- isDataFromSpreadsheet check for the creation wizard
- In ChartView (and VLegend) check if the data provider is a
  pivot chart data provider and get the pivot table field names
  to create the buttons on the UI.
- Adds the functionallity to show a filter pop-up (from calc)
  when clicking on row / column / page field buttons.
- Remove (X)PopupRequest as we won't need it.
- Add ODF import/export for pivot charts:
  + Added loext:data-pilot-source attribute on chart:chart
    which is the internal name of the pivot table with which the
    pivot chart is associated with. If the element is present, then
    the it means the chart is a pivot chart, else it is a normal
    chart
  + Added service to create pivot chart data provider through UNO
  + Add new methods to XPivotChartDataProvider to create value and
    label data sequences separately from the data source, which is
    needed for pivot chart import
  + When importing defer setting the data provider until a later
    time when we know if we are creating a chart od a pivot chart
- Pivot chart ODF round-trip test
- Add table pivot chart supplier API:
  This adds the XTablePivotChartSupplier and related interfaces so
  we can access, create, delete pivot charts from UNO in a sheet
  document. With this we now distinguish between normal charts
  and pivot charts. This was mainly needed because we can't extend
  the "published" interfaces of TableChartSupplier.
- Added an extensive test, which uses the API to create a new
  pivot chart when there was none, and checks that the pivot chart
  updates when the pivot table updates.

Change-Id: Ia9ed96fd6b1d342e61c2f7f9fa33a5e03dda21af
Reviewed-on: https://gerrit.libreoffice.org/36023
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
2017-04-04 13:39:29 +00:00
Markus Mohrhard 7f09093b8b the test seems to depend on the fonts
Fixes "Random Config" tb run #289

Change-Id: Ib1d672ac0a68e977f8d32f87c730ff1b0822f32c
Reviewed-on: https://gerrit.libreoffice.org/35109
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2017-03-12 22:25:06 +00:00
Tamás Zolnai 49d7bdea17 ChartDumpTest: A new chart test suite for a more sistematic testing
A hibrid of dumper tests (xmlDump) and simple CppUnit tests.
Advantages:
* Easy to add a new test case
** Add a new test file and generate the reference
** Similar to dumper tests
* Easy to find out the root of the problem when test fails
** Assertion is not coming somewhere from an XML file
** Assertion are placed in the code, so if you read and
understand that code, you can find out easier why the test fails.
** Similar to simple CppUnit tests.
* One test checks only one smaller part of the whole document
** e.g. legend, chart data, grid

Change-Id: I7bba5a37efcc62d6358c84acece91963243a914f
Reviewed-on: https://gerrit.libreoffice.org/34154
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2017-02-12 16:43:06 +00:00
Armin Le Grand ce6cbf86a5 screenshots: add new global make target
Up to now the screenshot creation was added/dependent of
target slowcheck. Since quite some modules have added screenshot
creations now, I added an own target 'screenshot' to allow to keep
current slowcheck and screenshot creation separated

Change-Id: I80a49a0db607edf8e0405672d570f624d29912e7
2016-08-18 02:39:15 +02:00
Armin Le Grand 56336f9762 screenshots: add dialog test cases for chart2
All *.ui files create a screenshot, but not all look useful

Change-Id: I90d977ae84a65e9576ba9cc9b178407997e4ba79
2016-08-18 02:39:12 +02:00
Tor Lillqvist e13aead8a1 Reduce ENABLE_OPENGL / ENABLE_HEADLESS confusion
ENABLE_OPENGL means whether to enable the OpenGL slideshow transition
code. It does not mean whether to enable use of OpenGL in general. So
rename it to ENABLE_OPENGL_TRANSITIONS while at it.

ENABLE_HEADLESS means whether to disable use of X11 and OpenGL on X11
(and Wayland) platforms, I think, meaning Linux and maybe Solaris and
the BSDs. Maybe it should be renamed to DISABLE_X11_AND_OPENGL.

Change-Id: Ibb30f51646b1bcc477fe691a3fa38c7a1e3944ae
2016-08-03 22:36:36 +03:00
Oliver Specht 96c1ae1d8e fix headless build
disables OpenGL and glew usage, lets --without-gui do what
--without-x did before and disables X related test

Change-Id: I680b47c9962a0d43c8ece593db0b82e347ceebdb
Reviewed-on: https://gerrit.libreoffice.org/23474
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Oliver Specht <oliver.specht@cib.de>
2016-03-25 11:05:47 +00:00
Markus Mohrhard f7b8bab7f3 related tdf#93676, add test for chart::CommonFunctors
Change-Id: I9667611135300155ee87cca1ad444ad8a6a9aeb1
2015-09-08 03:18:32 +02:00
Philippe Jung 733f5887af Add unit tests for chart2 trend calculators
Will be used to check tdf#70673 is fixed. Test will fail before the fix
and should pass after.

Change-Id: I9e0fdc696fb99ac2f0e24b04273391d526c629a6
Reviewed-on: https://gerrit.libreoffice.org/16406
Reviewed-by: Philippe Jung <phil.jung@free.fr>
Tested-by: Philippe Jung <phil.jung@free.fr>
2015-06-22 09:55:49 +00:00
Tor Lillqvist 20fc0ed8fa Build libchartopengl for all platforms
That doesn't mean it would need to be used on iOS or Android, if we
don't need/want to.

Change-Id: Ia6ac6f32cac3f6958f5ec240ec4be369474edfb8
2014-04-29 08:25:38 +03:00
Markus Mohrhard d8ae59e097 add concept for chart xshape tests
will be run on a tinderbox for now that will be the reference for
anything related to it

Change-Id: Ib795b53f74e9207d0272342f12d426bbc21164b4
2014-04-03 01:10:52 +02:00
Markus Mohrhard 40ea5e9dd0 Revert "Move OpenGLRender to vcl"
This reverts commit 04b70c682e.

The OpenGLRender is not abstract enough for vcl. Leave it in chart2.

Conflicts:
	chart2/source/view/inc/DummyXShape.hxx
	chart2/source/view/main/OpenGLRender.hxx
	vcl/Library_vclopengl.mk

Change-Id: I5392c8ee34462ff49059126ca2284d8ebe1eb379
2014-03-17 08:13:49 +01:00
Zolnai Tamás 04b70c682e Move OpenGLRender to vcl
Change-Id: I6383ae3f94fc18aec92596b9d857d3fde5869dd6
2014-03-14 19:59:21 +01:00
Tor Lillqvist 26cb65db74 Make the OpenGL stuff in chart2 compile for OS X (but definitely won't work)
Change-Id: I487fcd12bf90e8ce2c05743244858f7b5145c355
2014-02-03 17:48:26 +01:00
Peilin a7b0b253f0 add Symbol2D rendering
Change-Id: Ic294ffc4bc675495fe83ac182dbebbba7245c7b9
2014-01-29 08:09:56 +01:00
Michael Meeks d082e4fc38 Revert "disable building the OpenGL pieces"
This reverts commit 449157cae7.

Re-enable building the OpenGL pieces and limit it to Windows, Linux and
FreeBSD

Conflicts:
	chart2/Module_chart2.mk

Change-Id: I9edaaad4244b3c2c2b1174d91f57464dad69f214
2014-01-29 08:09:17 +01:00
Bjoern Michaelsen 78c7eb3507 uiconfig is a l10n-relevant target
Change-Id: I8a2ca73c02fd6b04ce60e7701c51d2362ef7ec06
2013-12-16 17:36:26 +01:00
Markus Mohrhard 449157cae7 disable building the OpenGL pieces 2013-11-19 13:47:41 +01:00
Markus Mohrhard 678008264f add glew and make chartopengl a dynamically loaded lib 2013-11-19 13:47:39 +01:00
Bjoern Michaelsen 04dead1c6b make l10n buildable separately
- this renames the 'almost' module target to non-l10n
- and adds a l10n target which is intended to only build l10n parts of
  the product
- packagers should then be able to build l10n and non-l10n parts of the
  product independently, thus:
   - enable quicker rebuilds
   - distribution of load
   - updates to l10n without a full rebuild
   - security fixes to binaries without rebuilding all l10n
- the new targets are called build-l10n-only and build-non-l10n-only
- note this is not intended to move a concept of split packages
  upstream -- while this exsists in distros, the number of test
  scenarios for this would explode upstream

Change-Id: Ib8ccc9bc52718d9b0ebbfee76ad93dc29c260863

Conflicts:
	filter/Module_filter.mk
2013-11-14 16:45:02 +01:00
Stephan Bergmann f3515761c0 Assume CppunitTest_chart2_import got removed by accident
...by 14c2ab3020 "add export test for charts."

Change-Id: I5c77276a80e15fff8d4042c3bc52f3094227d647
2013-05-14 19:14:44 +02:00
Stephan Bergmann 0ff2115b07 Fix naming
Change-Id: Ib2f9577429a4b9b97540de1eb40837ddafdc05b5
2013-05-13 15:02:22 +02:00
Markus Mohrhard 14c2ab3020 add export test for charts
Change-Id: I176f7967d37f3032057758d9aaa5f39c46d29c3d
2013-05-01 20:29:19 +02:00
Markus Mohrhard 171f11bfc9 actually this test should be fine as slowcheck test
Change-Id: Ie6f65f1ea2bfc61c9575b88957e6062c2c51566e
2013-04-22 13:57:32 +02:00
Michael Meeks 62badf3828 Move to MPLv2 license headers, with ESC decision and author's permission. 2013-04-22 09:37:38 +01:00
David Tardon bec67a2e7f deliver all uiconfig files by UIConfig
Change-Id: Ie78b7ce399ba34485146ca7622c59d31f8105d02
Reviewed-on: https://gerrit.libreoffice.org/3229
Reviewed-by: David Tardon <dtardon@redhat.com>
Tested-by: David Tardon <dtardon@redhat.com>
2013-04-11 03:39:16 +00:00
David Tardon ed72983131 rename UI to UIConfig
I plan to use it to deliver all */uiconfig files, not just .ui, as a
preliminary step to get rid of postprocess/packconfig.

Change-Id: Ie7b4434b2f247165e3ab69a4d0c193418720a149
Reviewed-on: https://gerrit.libreoffice.org/3225
Reviewed-by: David Tardon <dtardon@redhat.com>
Tested-by: David Tardon <dtardon@redhat.com>
2013-04-11 03:37:30 +00:00
Markus Mohrhard bc2f2ab20a move the dialog to chart2
Change-Id: I9f6e967d52dd10072c57b4f55faedd4ed7f98094
2013-03-28 10:11:02 +01:00
Markus Mohrhard 589ec7b7a1 slowcheck is not executed after everything is built 2013-03-05 11:28:51 +01:00
Markus Mohrhard 7cd6f8f7ad start for an initial chart2 import test
Change-Id: Iedd531186fccd73704eb3137195a22d3ca005293
2013-03-05 11:14:59 +01:00
Michael Meeks d10065ea3a merge pointlessly fragmented chart2 libraries, leaving controller split. 2012-08-06 10:33:46 +01:00
Takeshi Abe b2bd33ea25 prefer makefile-gmake-mode to plain makefile-mode 2011-08-10 02:12:48 +09:00
Tor Lillqvist 0ae6a22f45 Add consistent Emacs and vim mode lines 2011-07-30 23:01:11 +03:00
David Tardon c849643c98 gbuildize chart2 2011-04-15 12:46:03 +02:00
Bjoern Michaelsen 4618dd3983 migrate chart2 subsequenttests to gbuild 2011-03-28 02:45:25 +02:00