Version 7.5.1.1, tag libreoffice-7.5.1.1
[LibreOffice.git] / sc / inc / subtotalparam.hxx
blob8e36dad83987cd0c558e7f5cb441eff36cc5e386
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 */
10 #pragma once
12 #include "global.hxx"
13 #include <memory>
15 struct SC_DLLPUBLIC ScSubTotalParam
17 SCCOL nCol1; ///< selected area
18 SCROW nRow1;
19 SCCOL nCol2;
20 SCROW nRow2;
21 sal_uInt16 nUserIndex; ///< index into list
22 bool bRemoveOnly:1;
23 bool bReplace:1; ///< replace existing results
24 bool bPagebreak:1; ///< page break at change of group
25 bool bCaseSens:1;
26 bool bDoSort:1; ///< presort
27 bool bAscending:1; ///< sort ascending
28 bool bUserDef:1; ///< sort user defined
29 bool bIncludePattern:1; ///< sort formats
30 bool bGroupActive[MAXSUBTOTAL]; ///< active groups
31 SCCOL nField[MAXSUBTOTAL]; ///< associated field
32 SCCOL nSubTotals[MAXSUBTOTAL]; ///< number of SubTotals
33 std::unique_ptr<SCCOL[]> pSubTotals[MAXSUBTOTAL]; ///< array of columns to be calculated
34 std::unique_ptr<ScSubTotalFunc[]> pFunctions[MAXSUBTOTAL]; ///< array of associated functions
36 ScSubTotalParam();
37 ScSubTotalParam( const ScSubTotalParam& r );
39 ScSubTotalParam& operator= ( const ScSubTotalParam& r );
40 bool operator== ( const ScSubTotalParam& r ) const;
41 void Clear();
42 void SetSubTotals( sal_uInt16 nGroup,
43 const SCCOL* ptrSubTotals,
44 const ScSubTotalFunc* ptrFunctions,
45 sal_uInt16 nCount );
48 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */