1369 Commits
Author SHA1 Message Date
Xisco Fauli 7003eb6fc6 fix headers
Change-Id: Ia2732cc041367bc113654bc424ea6621f3961e9f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211724
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-10-05 08:52:04 +02:00
Kurt Nordback f81e4abac2 Axis and rendering fixes for funnel charts
Fix the plot direction and axis visibility for funnel charts created via the
UI (rather than imported from a file).

Signed-off-by: Kurt Nordback <kurt.nordback@collabora.com>
Change-Id: Iccf81a31d5f1ea8f9e63ffe369752e9c8a3f991d
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/8837
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit f5c7bc0a29c87993a83d9c492e8c545936e60a0e)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211424
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-09-24 16:12:36 +02:00
Andrea Gelmini 8ee79ac196 Fix typos
Change-Id: Ic7a97a5219d8a0d30b1753c2502995ea4c2cd32f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/210563
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Jenkins
2026-09-10 16:22:54 +02:00
Dennis Francis ce823e1cc7 chart2: say on the Data Range page which columns hold the dimensions
A correlation circle plot reads the ends of its range differently from every
other chart type: the last two columns are the dimensions its points are placed
against and the columns before them are the features. One range holds the lot,
so nothing about the entry gives that away, and a reader who does not already
know it has no way to work it out.

Display a information label under the range input saying the last two
columns of it are component dimensions and the columns before that are
features.

Change-Id: Ib7d27aad189f12be188f61b1fc317dd1e718b803
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/8105
Tested-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
(cherry picked from commit 2cbf62e18df956ed23c77932cd5e38424e7baa1f)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/210470
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-09-04 15:05:11 +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
Dennis Francis b0b4bad01f chart2: add a correlation circle chart type
A correlation circle plot shows how each feature of a table relates to the
first two dimensions of a decomposition of that table, which a user can now
work out in a spreadsheet with MSVD. One point per feature sits at the
correlation of that feature with the first dimension across and with the
second dimension up, inside a circle of radius one.

The data arrives as one series per feature. Each series holds its own feature
column under the new role values-feature, together with the two dimension
columns under values-x and values-y, which every series shares the way the
bubble chart shares its x column. Keeping the dimensions on the x and y roles
means the point count, the axis scaling and the label machinery need no
special case, and the series label comes from the feature column header, so
the legend and the point labels read as feature names.

The interpreter reads a flat list of columns as a feature table followed by
two dimension columns: the last two are the dimensions and every column before
them is a feature. One range holds the lot, which is what the wizard hands
over, and it is also the order the list comes in when a chart of another type
is turned into this one. A first column of instance names is kept out of the
features when the range says it has them, as it is for a bubble chart.

Both dimensions are numbers running from minus one to one, so the chart type
joins the scatter and the bubble chart in asking for a numeric axis across.
That answer is also what turns the axis of names back into a numeric one when
a chart of another type becomes this one, since the coordinate system the
other type left behind is kept and reused.

Change-Id: Id17d3a2a235c849c3dab9768159ddf1608da6d05
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/8102
Tested-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
(cherry picked from commit b30d992bba26428941f47f952baf338df3763065)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/209379
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-09-03 17:07:43 +02:00
Tomaž Vajngerl 3aa0160c31 Bound the number of histogram bins
A bin width much smaller than the data range asks for a bin count
with no upper bound. Over a range of 1000 a width of a millionth
resolves to a billion bins. The conversion from double to sal_Int32
had no range check either, so it could overflow.

Cap the count at MAX_HISTOGRAM_BINS. The division stays in double
and saturates at the cap, and a fixed count from a document is
clamped the same way.

A capped count no longer spans the range with the requested width,
so the range is divided evenly instead. Scott's rule gets the same
treatment when it yields no width at all.

Signed-off-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>
Change-Id: Ib59ee462edade94799cc58e503b843696743ecfe
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/10257
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit 93a9df897a14ec12457aa40d328616eb071a9175)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/210337
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-09-01 19:49:22 +02:00
Devansh Varshney 22b73ccfdc chart2: keep histogram axis labels in sync with bin settings
Histogram bin-property changes regenerated the category sequence stored
on the data series, while the X axis continued referencing the previous
sequence. This left the chart bars updated but displayed stale bin
labels.

Keep the category sequence produced by HistogramDataInterpreter on both
the diagram axis and data series. Update its binning parameters in place
when histogram properties change, allowing existing listeners to
recalculate and redraw the axis labels.

Signed-off-by: Devansh Varshney <varshney.devansh614@gmail.com>
Change-Id: Ibd6679bddf29de5fa1fd903af9274259b2e9c243
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/9282
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Tested-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
(cherry picked from commit 0103afa2a6a746ce54a0e3e4297e1fa60698ef03)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/209218
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-01 14:00:42 +02:00
Andrea Gelmini 8ebe4b6d28 Fix typos
Change-Id: I9bf770374a5ee585f1aa99a0bb10f72d04a7c825
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/210152
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Jenkins
2026-08-29 16:25:37 +02:00
Andrea Gelmini 97b083f7ab Remove duplicated line of code
Change-Id: I7bb9bff4da5121c457f7550b037409d6d1dd11da
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/210144
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2026-08-28 16:16:43 +02:00
Kurt Nordback 160014f44b Initial implementation of rendering for funnel charts
Framework for funnel chart rendering. For now this just renders them as
horizontal bar charts: that is, not properly centred as a funnel. UI
functionality is untested and probably broken.

Signed-off-by: Kurt Nordback <kurt.nordback@collabora.com>
Change-Id: I3a0e923b801c840138c90dcf3609253a467d23d1
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/7905
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
(cherry picked from commit 172e4233b70f1d73ca942876f3f47458843ffa36)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/209739
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-08-25 08:52:54 +02:00
Andrea Gelmini 7ec662d6e2 Fix typos
Change-Id: Ib1b4ee06e762b4cc4a7240b4ead79be2f70b6233

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/209776
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2026-08-24 09:17:48 +02:00
Kurt Nordback d72a7d1be6 tdf#165742 Step 5.15: Don't export default shape props (continued)
In more cases, avoid exporting spPr when the intent is to use the default
value. Explicit spPr locks the settings, preventing override by styles, for
instance.

Signed-off-by: Kurt Nordback <kurt.nordback@collabora.com>
Change-Id: Ic73016a4d3ac3ebd0d3739a2c76dfaa3d9a70d4c
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/7903
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit dcbcd6246f137dec36763a2824463a9246c6cf68)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/209242
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-08-19 08:42:01 +02:00
Kurt Nordback b6a5834277 tdf#165742 Step 5.14: Assorted axis unit fixes
Support round-trip for axis min, max, majorUnit, minorUnit, and some
handling for numFmt, all for chartex.

Signed-off-by: Kurt Nordback <kurt.nordback@collabora.com>
Change-Id: Ibef74b0efc27d5ff7923800b169603758e276ada
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/5901
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit 05420f729d5399c127d9a15fcad043fa6673dd6a)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/209241
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-08-18 15:53:56 +02:00
Kurt Nordback 0c8160d7e8 tdf#165742 Step 5.13: Support ownerIdx attribute
It appears that the ownerIdx attribute of <cx:series> is used to indicate
that series share data. At least that seems to be the case with pareto
charts, which have both a clustered column and a pareto line series. Going
on that assumption, implement parsing/export of ownerIdx, and don't write
a dataId tag when ownerIdx is present. That fixes round-tripping of
pareto charts, at least based on what I've seen.

Signed-off-by: Kurt Nordback <kurt.nordback@collabora.com>
Change-Id: Ie948d2e5992b778462e34e1ef90681631c867332
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/5900
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit 8c37a25ffb7711f69de978045b4e3dc8d52759da)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/209240
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-08-18 15:53:52 +02:00
Kurt Nordback c26599741c tdf#165742 Step 5.12: Improve axis handling
Implement better handling of <cx:axisId> and <cx:axis> tags. In particular,
ensure we output the correct number of axisId elements, based on the chart
type, and ensure that corresponding axes (and only those) are captured in the
appropriate <cx:axis> data.

Signed-off-by: Kurt Nordback <kurt.nordback@collabora.com>
Change-Id: Ifed17afc05c70dced89e75f18dcf375fdef97f6e
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/5775
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit 833f782bca98c891097d887a45365bc7a5322c4d)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/209239
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-08-18 13:08:26 +02:00
Kurt Nordback f201337f3b tdf#165742 Step 5.11: Don't output empty tick mark tags in chartex
Chartex has different tick mark defaults from old-style charts. Don't
output <cx:majorTickmarks> or <cx:minorTickmarks> when no tick marks are
intended, including if there were no such tags on input.

Change-Id: Ib6caecaca917204ddc99208cbece8f6adff8f5ca
Signed-off-by: Kurt Nordback <kurt.nordback@collabora.com>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/3067
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
(cherry picked from commit 5353e467dea04ba6b12b616b90e269f0a096375a)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/208843
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-07-30 17:13:30 +02:00
Devansh Varshney 09823632bd chart2: add histogram underflow/overflow bin model support
Add model properties for optional underflow and overflow bins on
histogram chart types, and expose them through the HistogramDiagram
wrapper.

Pass the new settings through the existing histogram pipeline:
HistogramChartType snapshots the properties, HistogramDataSequence keeps
that snapshot, and HistogramCalculator creates optional edge bins around
the normal bin range.

Generated category labels now distinguish special bins from normal ranges,
e.g. "<= 11", "(11-13]", and "> 14".

Add a model-level test that sets fixed bin width together with underflow
and overflow bins, then verifies that the generated bin labels are rebuilt
correctly.

Signed-off-by: Devansh Varshney <varshney.devansh614@gmail.com>
Change-Id: I65eac9607daa4f4be6320304c9e9682549f479a6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/207151
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-06-29 14:35:14 +02:00
Devansh Varshney 48ef1cbacc chart2: update histogram bins after bin-count changes
HistogramDataSequence snapshots the histogram binning
settings when the calculated-y and category sequences
are created. Rebuild those sequences when BinWidth,
BinCount, or FrequencyType changes, so fixed-bin settings
take effect immediately.

For XLSX import, use the regenerated histogram series
categories as the X axis categories. Keeping the existing
axis categories can preserve stale bin labels, e.g. after
reloading a chart exported with cx:binCount.

Extend the histogram roundtrip test to verify that fixed
bin count creates the expected bin labels after ODF
and XLSX reload.

Signed-off-by: Devansh Varshney <varshney.devansh614@gmail.com>
Change-Id: I718bbfe537d847de6c17ea7742a9c4d231b57b7c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/207007
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-06-29 14:28:58 +02:00
Kurt Nordback 1403eb3621 tdf#165742 Step 5.10a: Only export non-default dataLabels
Don't always output series dataLabels element for chartex. Only output it if
necessary, meaning a non-default value.

Change-Id: Ie47b956cde0337bb82b268725c77d511da981d41
Signed-off-by: Kurt Nordback <kurt.nordback@collabora.com>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/2966
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
(cherry picked from commit 38af704dc0a8feab90007fbf3cd5388e0efd8294)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/206025
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-06-05 12:02:22 +02:00
Kurt Nordback a16459fc63 tdf#165742 Step 5.10: Don't export default shape props
Don't export a series shape properties (spPr) for chartex charts if none was
present on input. Also a basic test for this.

Signed-off-by: Kurt Nordback <kurt.nordback@collabora.com>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/2961
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit 32886b30c0539bfe1443434beeb1b3b27c93a4a7)
Change-Id: I5daf1d49762fe3b32c1c9254e0792b9eb34494e5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/205699
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-05-26 19:48:18 +02:00
Devansh Varshney 6829e82577 chart2: Implement Scott's Rule and Histogram Data Interpreter
This commit introduces the mathematical backend and data interpreter for
the Histogram chart, replacing the temporary raw value rendering.

- Adds HistogramCalculator, utilizing Scott's Rule to calculate optimal
bin widths and frequencies from raw data.
- Introduces HistogramDataSequence that listens to spreadsheet data
changes and automatically regenerates bin categories and frequencies
- Implements HistogramDataInterpreter to intercept raw values-y input,
and output the results into the calculated-y data sequence.

Change-Id: Iaf29ddd0b0824bd3f0808ffc91321cad9d5b877e
(cherry picked from commit 1ef619a998aba626d0ea7a9541109a7c9e145518)
Signed-off-by: Devansh Varshney <varshney.devansh614@gmail.com>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/1879
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit df68284255ccac4bd86583555986d9f7cbdddf9a)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/203747
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-05-23 00:09:41 +02:00
Devansh Varshney 048b35b49d chart2: Add UI and basic rendering for Histogram chart
This commit introduces the structural foundation and user interface for
the new Histogram chart type. The rendering engine gracefully falls
back to plotting the raw values-y input data directly. As a result, the
chart currently renders identically to a standard bar/column chart.

- Adds UI entries in the Chart Type dialog.
- Adds HistogramChart to the view layer, inheriting from BarChart and
forcing a 0-gap width.

Change-Id: Ica5b15e9b7428d6c908e1b978259367fe8ff7aab
(cherry picked from commit 14a4a09b62fc283f9b629a2a317156efa6509054)
Signed-off-by: Devansh Varshney <varshney.devansh614@gmail.com>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/1878
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit 508c3456e85a88771ac5e264cee9460274685a22)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/203741
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-05-23 00:09:33 +02:00
Devansh Varshney 2049356d4f chart2: avoid overwriting values-y
Implements a new calculated-y data structure which will be
useful in new chart types like histogram charts where the
axes are modified and hence have to preserve original raw
input values.

Change-Id: I339211d700501f263201a977741206cdb73e1cea
(cherry picked from commit 7bcf35bc40a3d0bb7452cff56c88d8b86c4b2d79)
Signed-off-by: Devansh Varshney <varshney.devansh614@gmail.com>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/1877
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit 48a8b3165c543d1b46b92c1cf4941adc40fc11cd)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/203687
Tested-by: Xisco Fauli <xiscofauli@libreoffice.org>
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-05-23 00:09:26 +02:00
Kurt Nordback 8bf5b36ce1 tdf#165742 Step 5.9e: Store enumerated geography parameters as enums
The projection type and region type are described in the OOXML spec as
enumerated values. Store them internally as such, converting from string on
input and to string on output.

Change-Id: I5ee9b6996362bf8cc8db28fc921f3b95bfb7ff46
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/2065
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
(cherry picked from commit 00cb914655c1250656f81eed96ffd9df198387fb)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/204761
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-05-14 12:54:34 +02:00
Kurt Nordback cf04cdbcfa tdf#165742 Step 5.9d: Support for <cx:geography> tag
Add support for import, storage, and export of <cx:geography> and its
children. This tag is used to express geography for regionMap charts. Also
includes one simple round-trip test.

Change-Id: Iccaef8b8cd2848ae3e48532c72507469c55ebefc
Reviewed-on: https://gerrit.collaboraoffice.com/c/core/+/719
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
(cherry picked from commit d5bfa4677609d5618a82d4aa3e182bba00054a01)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/204150
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-04-23 15:47:47 +02:00
Kurt Nordback 8cbd028c0b tdf#165742 Step 5.9c: Support for gapWidth tag import/export in chartex
The gapWidth tag specifies spacing for bar/column-like charts. In old-style
charts, it's given in the type group. In chartex, it is an attribute of the
<cx:catScaling> child element of <cx:axis>. This code thus includes some
structural changes to allow for reading the value in the axis processing
and storing it in the PropertySet associated with a type group (XChartType).

Change-Id: I21bdf3b511269c34c225873ee66fbaf29a7cb0ea
Reviewed-on: https://gerrit.collaboraoffice.com/c/core/+/718
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
(cherry picked from commit bb1d3ba56f5b17d0979addac95a3973278d2f46b)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/204149
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-04-23 13:37:59 +02:00
Kurt Nordback 03ecbbadd4 tdf#165742 Step 5.9b: Support more children of layoutPr
Provide round-tripping support for parentLabelLayout, regionLabelLayout,
statistics, and subtotals tags.

Change-Id: I6d5fb04ce54061dbb1e886157f9869030ff941d4
Reviewed-on: https://gerrit.collaboraoffice.com/c/core/+/717
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
(cherry picked from commit e91d8ff7a4cd84f444a9b01b64ad6df8d45f910e)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/204148
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-04-23 13:37:43 +02:00
Kurt Nordback 9db38b095c tdf#165742 Step 5.9a: Support visibility child tag of layoutPr
Provide round-tripping support for the <cx:visibility> child of
<cx:layoutPr> in chartex.

Change-Id: I23f4058e67cb00fa986f6a4e7d1c63e97d44a4d0
Reviewed-on: https://gerrit.collaboraoffice.com/c/core/+/688
Reviewed-by: Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit ef7013f120422cc796e8994ff7ba1396c5e84609)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/204147
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-04-23 13:37:34 +02:00
Xisco Fauli 5d9dfab134 Revert "tdf#165742 Step 5.10: Don't export default shape props"
This reverts commit d160c4a17d.

Pushed accidentally.

Change-Id: I3ffb711f953cd0e1b9e3a92ac6852618bd72cf83
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/204166
Tested-by: Xisco Fauli <xiscofauli@libreoffice.org>
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-04-23 13:36:50 +02:00
Kurt Nordback d160c4a17d tdf#165742 Step 5.10: Don't export default shape props
Don't export a series shape properties (spPr) for chartex charts if none was
present on input. Also a basic test for this.

Change-Id: I1692e8dbd160fa7d0db6fd0d50ca1ba42a9e9fca
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/202633
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-04-23 13:33:41 +02:00
Mehul Sharma 4381d485fc tdf#163738 Use insert() to add multiple values in containers
instead of loop

Replace push_back with corresponding insert without changing the
behaviour of the code

Change-Id: Ib09ee67400131d68ce84148b8affcc881aecdd38
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/203415
Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
Tested-by: Jenkins
2026-04-11 07:24:04 +02:00
Kurt Nordback c26dd0e1f2 tdf#165742 Step 5.8: Add minimal support for layout props
Add framework for import/export of chartex layout properties (cx:layoutPr).
Also support the child cx:binning property, used for clusteredColumn charts
(and perhaps others). This allows the binning property to round-trip
successfully MSO -> LO -> MSO.

Change-Id: I54bd1692ce4fb59dd70c9d4ac68f108c33cbca8a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/199553
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2026-03-24 06:57:32 +01:00
Noel Grandin 4b10710e09 loplugin:passstuffbyref
Change-Id: I559d246b25c99e5cb7a28ba94e04a2acedd3e720
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/200943
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2026-03-04 19:22:19 +01:00
Noel Grandin 8d5a6870a7 InternalDataProvider constructor always has
bDefaultDataInColumns == true

Change-Id: I93c64a310852f1b823327874d9cc487c653c6222
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/200860
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2026-03-03 07:58:19 +01:00
Gabor Kelemen a9e9175ba6 tdf#146619 Use more forward declarations in include/sfx2
This shaves off some 300M of input
Change-Id: I2fae9ff6c6dab31010986e55365676d4a01f402d

Change-Id: I3b2551a1937929100f25c01c0c416a419e7fbb51
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/199388
Reviewed-by: Gabor Kelemen <gabor.kelemen@collabora.com>
Tested-by: Jenkins
2026-02-23 12:19:48 +01:00
Xisco Fauli 76ef93a709 crashreporting: fix crash in impl_createReferenceSizeProvider()
Seen in https://crashreport.libreoffice.org/stats/crash_details/deb8f144-001b-4f79-9a7b-c0e8dd7d8c55

Most likely after
commit 76d296f760
Author: Noel Grandin <noelgrandin@gmail.com>
Date:   Thu Apr 10 20:02:01 2025 +0200

    fold ChartModelHelper functions into ChartModel

Change-Id: I959b1210254e741ac9dca492f2e70d86e86f3929
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/197083
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2026-01-12 17:00:44 +01:00
Kurt Nordback 2dba43e317 tdf#165742 Step 5.1: Support basic I/O for additional chartex types
Previous work on this project added support for Funnel charts, one of the
chartex types. This commit expands that to all the other chartex types,
including RegionMap. Largely this is parallel to what was done for Funnel,
but there are some namespace differences, and ParetoLine requires some special
handling because Microsoft Office seems to encode it as a combination of
clusteredColumn type and paretoLine type. ParetoLine support is incomplete,
especially on the export side.

Change-Id: Ib751632ec05f3fbf248e0f194f7a6f36f2fa6a88
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194933
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2026-01-09 07:21:24 +01:00
Noel Grandin bc8765cd9f loplugin:unusedmethods
Change-Id: Ib11352e8abb69b0923a19005f5eb1d4a0c748107
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196155
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2025-12-23 17:12:09 +01:00
Kurt Nordback 0686b19728 tdf#167941 - Chart color sequence OOXML import/export
Support import, storage, and export of OOXML chart color styles
(color sequence). In OOXML, chart color styles are in files such
as colors1.xml, and conform to the chartStyle schema. This commit
supports I/O of color styles, and provides supports storing them
in the chart document model. It does not include any features for
using or modifying the color styles, so at this point it has no
appreciable effect on users.

Change-Id: I5c02137ebf9c25e11951eea55c4c77fda35b0e80
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194998
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2025-12-05 02:12:41 +01:00
Tomaž Vajngerl f15e0583c2 chart2: Add ComplexColor to many properties of chart elements
This adds ComplexColor to many of the color properties that are
available in charts. It also handles some import code in oox, so
the complex colors are set correctly to the chart elements if an
OOXML document is loaded. This doesn't yet handle export and if
a theme is changed, as well if a color is changed manually in
the chart.

Change the tests so they now assert the scheme color like it is
defined in the source document and not the calculated derived
color.

In addition change the WriteRunProperties to have a struct as
an input instead a number of parameters, which in most cases don't
need to be filled out and are using the default value.

This was needed for the new parameter bUseTextSchemeColors, which
is used for charts, so the text colors use tx1 and tx2 elements
instead dk1 and dk2, which are usually used in Impress.

Change-Id: Iaebbaea983c5232c51233c1a02bd8fe1da24d551
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194939
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2025-12-04 08:21:07 +01: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
Tomaž Vajngerl 58d2a68530 tdf#164593 Revert "tdf#82716 Add initial implementation of the His.."
This reverts commit 07ae0e5ada.

As discussed in https://lists.freedesktop.org/archives/libreoffice/2025-November/093988.html

(cherry picked from commit 9693f1461c7d78c7461f8bbd7f421ba8c3f8452b)

Change-Id: Ifd4008d62f9816d995f97104ba432ebc8be89c97
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/186407
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Signed-off-by: Xisco Fauli <xiscofauli@libreoffice.org>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/193983
2025-11-14 08:44:54 +01:00
Silvery Freakz 86488ad12d Use assign() instead of insert()
Since aOldBroadcasters is empty at this point, assign() is efficient than insert(). This is a cleanup following the already merged patch.

Change-Id: I8315a5c8021a67f003f84f3002a13c1511dc04c5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/192744
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Tested-by: Jenkins
2025-10-21 06:36:24 +02:00
codemaestro 4ce8861dd5 tdf#163738 Use insert() to add multiple values in containers instead
of a loop

Change-Id: Ia8d4fa56dcb1e3b105a38b083365e35927d38384
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/192582
Tested-by: Jenkins
Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
2025-10-20 12:18:13 +02:00
Mike Kaganski a255b04d8d Shorten some names ending with _ASCII
Whatever that was intended to mean: if that meant that the constants
were encoded that way, these are UTF-16 already; is that meant that
they only contained characters in that range, that is unimportant.

Change-Id: I5463f1fca0d552a93d3c9d487ed9912c9e1a989e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/191240
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Tested-by: Jenkins
2025-09-20 19:35:12 +02:00
Kurt Nordback 33bbf0bd20 tdf#167941 - Chart style file is not supported in OOXML
Parse the style*.xml file in the OOXML package, and store the imported
styles in XChartDocument via a new XChartStyle. Some areas are yet to be
fleshed out, but the intent here is to get a review of the general approach
and architecture. This includes no work on the export side (or the UI and
application of styles to a chart, which is a separate but related project).

Change-Id: I9d5b9f5aa44fb7944b2d971edc26e04dc2256c7f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189531
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2025-09-03 16:54:45 +02:00
Noel Grandin 423f95aa13 tdf#168191 Incorrect labels of X-Axis in chart
revert
    commit eeb8ca44ac
    Author: Noel Grandin <noel.grandin@collabora.co.uk>
    Date:   Fri Apr 4 10:02:06 2025 +0200
    tdf#147874 slow sheet switching with large chart2 (2)

Change-Id: I67dcea417be01982b769dd2bea387b4d29f0e732
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/190520
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
2025-09-02 15:46:41 +02:00
Marco Cecchetti 150525a38e lok: color preview: avoid chart color palette reset on preview
Notify color preview state: enabled/disabled
Avoid current color palette to be cleared if user is just previewing a
color for a data series or a data point with the color picker.

Change-Id: I8b5fcd7e675d34f68b0323703ec509493fc48492
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/186337
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/190035
Tested-by: Jenkins
Reviewed-by: Marco Cecchetti <marco.cecchetti@collabora.com>
2025-08-24 23:21:44 +02:00
Gabor Kelemen 85f88d7196 tdf#146619 Run IWYU on chart2/
Change-Id: I2f0920df37ba14918e1325983309f9b77c8792cb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188751
Tested-by: Jenkins
Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2025-08-18 20:19:39 +02:00