Commit Graph
24 Commits
Author SHA1 Message Date
Balazs Varga ed43e7866c Table Styles: make the SetCustFuncs and SetSubLabels consistent
Since these two functions are index based we should check
nGroupIdx >= MAXSUBTOTAL even if we only pass '0' in nGroupIdx, because
later maybe can be used multiple (3) groups in Table Styles Total rows.

Follow-up: d5c36d5e775fa48c011570eb876317c21727baa0
(Table Styles: fix not removed total function in case of)

Change-Id: Iad2981d2c82bd58f16b7bea72faeb5c51bc77635
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/199472
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga@collabora.com>
2026-02-16 19:54:23 +01:00
Balazs Varga f1f0c14ffa Table Styles: fix not removed total function in case of
0 new value. Remove/reset total functions or labels if
have no any new ones.

Change-Id: Ibac6d172b7d3ed0146e35177f7c8831ad34974b8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/195075
Reviewed-by: Balazs Varga <balazs.varga@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196775
Tested-by: Balazs Varga <balazs.varga@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/198001
Tested-by: Jenkins
2026-01-29 09:33:40 +01:00
Balazs Varga 14ad804261 Table Style improvements: Handle custom functions in Total row
of table styles

Also rework and better (more dynamic) handling of
Total row. Also fix the additional ooxml import
problems around Total row.
cherry-pick from: bca5864a3245021601991e9be8ff6401ffd812b5

Include fix unit test builds failer because of
missing function parameteres.

Include: ooxml export of Total Row attributes. XML_totalsRowLabel,
XML_totalsRowFunction, XML_totalsRowFormula and XML_totalsRowShown.
cherry-pick from: dbe65f04327924e0d3c7bcefab5bbfba07687033

Change-Id: I894c309362cfaf525ebbf47e7f49bc67b8da8495
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/193205
Reviewed-by: Balazs Varga <balazs.varga@collabora.com>
Tested-by: Balazs Varga <balazs.varga@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/193681
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196749
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/197975
Tested-by: Jenkins
2026-01-29 09:28:52 +01:00
Balazs Varga 23588210d6 Handle various Total row situation in table style
Extending Table area with Total rows on and off.
Moving Table total row when we extend table area.
Show and hide/remove total row with Show Total Row buttom.
Handle Undo / Redo of resized table area.
Handle TotalsFunction (only subtotal so far - TODO) in Total row.
Handle TotalsRowLabel (also OOXML import export) in Total row.
Fix rendering issue after undo dbrange of table styles change.

TODO: handle not only Subtotal functions
TODO: Autofilter dropdown shows not only Table area values
TODO: Redo, remove autofilter flags after undo/redo horizontal
table extension (adding columns)

cherry-pick from: bb9998dcbadd81a71f97921e4ee2ff1921eefee1

Change-Id: Ifaa3df0693d716cf22e566244c449f85dcd91d8a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/192920
Reviewed-by: Balazs Varga <balazs.varga@collabora.com>
Tested-by: Balazs Varga <balazs.varga@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/193678
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196746
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/197972
Tested-by: Jenkins
2026-01-29 09:28:19 +01:00
Mike Kaganski 669c839a61 Simplify ScSubTotalParam
Change-Id: I4c1840e377711ad065c3042bddacb2028481b88d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/177433
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-11-28 05:36:59 +01:00
Xisco Fauli ec68e9884a PVS: V560 A part of conditional expression is always true: bEqual
Since
commit d0484bcdcb
Author: Jens-Heiner Rechtien <hr@openoffice.org>
Date:   Mon Sep 18 23:16:46 2000 +0000

    initial import

Change-Id: Ib1cf69ecf70bf9d866308892562a2d9080e1350f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/177413
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2024-11-27 14:23:29 +01:00
Balazs Varga 26c08356d1 tdf#162262 sc add "Summary below data" option for Subtotal dialog
With this option we can set where the summary rows should appear,
above or below the datas when we create a new Subtotal area. The default
option is "True" (which means the summary rows are below the datas)
when we create a new subtotal area. Unless if we already have one subtotal
area on the same sheet, in that case the sheet level property, "TotalsRowBelow"
contains where should the summary rows be for the new Subtotal's.

TODO: add new ODF xml attribute for Summary below

Change-Id: Icf86c85041d75c24919cb528846d5bb2b517ca78
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175556
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2024-10-28 13:28:21 +01:00
Noel Grandin 203288c830 fix leak in ScSubTotalParam
Change-Id: If839585931fc90b9910f6b95338d59ba48a1a78f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115676
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-16 20:45:33 +02:00
Noel Grandin 75f398b22a loplugin:flatten in sc/core/data
Change-Id: I9ffe58d68172c6fe9c76000c01c0c67a03967146
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99699
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-07-30 09:59:39 +02:00
Tamás Zolnai 3a5d78365d clang-tidy: Fix suspicious catches of WIP unhandled-self-assignment check
Change-Id: I1cb16b180f4cc5bf4d65485f03c44a06414d3580
Reviewed-on: https://gerrit.libreoffice.org/70481
Tested-by: Jenkins
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2019-04-10 01:06:19 +02:00
Stephan Bergmann 3e1d3c25e0 loplugin:includeform: sc
Change-Id: I2ed763e0584a188032c80fde60890de3c6985cbd
2017-10-23 22:45:57 +02:00
Stephan Bergmann de29ac0953 loplugin:nullptr (automatic rewrite)
Change-Id: I765d2a600f9c57da50c85354688e3ae796750d94
2015-11-10 10:31:36 +01:00
Albert Thuswaldner 7da33e8c53 Translated german comments in sc/source/core/data/ #2
Change-Id: Ia8a0235b8acb5c76c195e280a75256f6b82684bb
Reviewed-on: https://gerrit.libreoffice.org/14372
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-02-12 09:56:15 +00:00
Michael Stahl 6a0fe37dec sal: clean up public headers with include-what-you-use
Sadly cannot forward declare "struct {...} TimeValue;".

rtl/(u)?string.hxx still include sal/log.hxx but removing osl/diagnose.h
was painful enough for now...

Change-Id: Id41e17f3870c4f24c53ce7b11f2c40a3d14d1f05
2014-11-17 11:06:53 +01:00
Markus Mohrhard 37e6631cc5 remove whitespace
Change-Id: Ib15413e73409cc33de01fa92a47b9d1237cfc4b2
2014-06-25 05:41:10 +02:00
Markus Mohrhard c4c51709ea whitespace cleanup in sc
Change-Id: Id1dcadcac179c52977e48a6912ce4d5fd542f60c
2014-04-06 17:19:54 +02:00
Alexander Wilms 0ce0c369aa Remove unneccessary comments
Change-Id: I939160ae72fecbe3d4a60ce755730bd4c38497fb
Reviewed-on: https://gerrit.libreoffice.org/8182
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-02-23 03:38:49 +00:00
Michael Meeks 03993b47c5 targetted clean of redundant header piece from 62badf3828
Change-Id: Ic1240114d667fb7797afae4847427cc889f3cb48
2013-07-26 14:18:52 +01:00
Markus Mohrhard 67b944c021 coverity#705449: comparing array against NULL
Change-Id: I92ba78e96ad4f7c4a661dd879a721e422b6d0d2e
2013-05-09 23:29:45 +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
Norbert Thiebaud 2721235724 remove include of pch header from sc 2011-11-27 13:20:15 -06:00
Caolán McNamara 2774cab826 add modelines 2011-09-29 09:33:46 +01:00
Jacek Wolszczak 45df4e3859 Replace DBG_* with OSL_* in sc/source/core 2011-05-27 06:03:37 +02:00
Kohei Yoshida d7d3d778b5 Moved ScSubTotalParam from global.* into own files. 2011-03-23 23:11:07 -04:00