LibreOffice Module sc (master) 1
tpformula.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
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 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
20#pragma once
21
22#include <sfx2/tabdlg.hxx>
23
24#include <calcconfig.hxx>
25#include <docoptio.hxx>
26
28{
29public:
30 explicit ScTpFormulaOptions(weld::Container* pPage, weld::DialogController* pController,
31 const SfxItemSet& rCoreSet);
32 static std::unique_ptr<SfxTabPage>
33 Create(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet* rCoreSet);
34 virtual ~ScTpFormulaOptions() override;
35
36 virtual bool FillItemSet(SfxItemSet* rCoreSet) override;
37 virtual void Reset(const SfxItemSet* rCoreSet) override;
38 virtual DeactivateRC DeactivatePage(SfxItemSet* pSet) override;
39
40private:
41 void ResetSeparators();
43 void UpdateCustomCalcRadioButtons(bool bDefault);
45
46 bool IsValidSeparator(std::u16string_view aSep, bool bArray) const;
47
48 DECL_LINK(ButtonHdl, weld::Button&, void);
49 DECL_LINK(ToggleHdl, weld::Toggleable&, void);
50 DECL_LINK(SepInsertTextHdl, OUString&, bool);
51 DECL_LINK(ColSepInsertTextHdl, OUString&, bool);
52 DECL_LINK(RowSepInsertTextHdl, OUString&, bool);
53 DECL_LINK(SepModifyHdl, weld::Entry&, void);
54 DECL_LINK(SepEditOnFocusHdl, weld::Widget&, void);
55
56private:
59 OUString maOldSepValue;
60
63
66
68
69 std::unique_ptr<weld::ComboBox> mxLbFormulaSyntax;
70 std::unique_ptr<weld::CheckButton> mxCbEnglishFuncName;
71
72 std::unique_ptr<weld::RadioButton> mxBtnCustomCalcDefault;
73 std::unique_ptr<weld::RadioButton> mxBtnCustomCalcCustom;
74 std::unique_ptr<weld::Button> mxBtnCustomCalcDetails;
75
76 std::unique_ptr<weld::Entry> mxEdSepFuncArg;
77 std::unique_ptr<weld::Entry> mxEdSepArrayCol;
78 std::unique_ptr<weld::Entry> mxEdSepArrayRow;
79 std::unique_ptr<weld::Button> mxBtnSepReset;
80
81 std::unique_ptr<weld::ComboBox> mxLbOOXMLRecalcOptions;
82 std::unique_ptr<weld::ComboBox> mxLbODFRecalcOptions;
83};
84
85/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
std::unique_ptr< weld::Entry > mxEdSepArrayCol
Definition: tpformula.hxx:77
static std::unique_ptr< SfxTabPage > Create(weld::Container *pPage, weld::DialogController *pController, const SfxItemSet *rCoreSet)
Definition: tpformula.cxx:256
DECL_LINK(ToggleHdl, weld::Toggleable &, void)
sal_Unicode mnDecSep
Definition: tpformula.hxx:67
std::unique_ptr< weld::ComboBox > mxLbFormulaSyntax
Definition: tpformula.hxx:69
std::unique_ptr< weld::RadioButton > mxBtnCustomCalcCustom
Definition: tpformula.hxx:73
ScCalcConfig maCurrentConfig
Definition: tpformula.hxx:62
DECL_LINK(RowSepInsertTextHdl, OUString &, bool)
DECL_LINK(ButtonHdl, weld::Button &, void)
bool IsValidSeparator(std::u16string_view aSep, bool bArray) const
Definition: tpformula.cxx:133
std::unique_ptr< weld::Button > mxBtnSepReset
Definition: tpformula.hxx:79
virtual ~ScTpFormulaOptions() override
Definition: tpformula.cxx:82
virtual DeactivateRC DeactivatePage(SfxItemSet *pSet) override
Definition: tpformula.cxx:405
ScTpFormulaOptions(weld::Container *pPage, weld::DialogController *pController, const SfxItemSet &rCoreSet)
Definition: tpformula.cxx:34
DECL_LINK(SepEditOnFocusHdl, weld::Widget &, void)
DECL_LINK(SepModifyHdl, weld::Entry &, void)
DECL_LINK(ColSepInsertTextHdl, OUString &, bool)
ScCalcConfig maSavedConfig
Definition: tpformula.hxx:61
void UpdateCustomCalcRadioButtons(bool bDefault)
Definition: tpformula.cxx:107
void ResetSeparators()
Definition: tpformula.cxx:86
std::unique_ptr< weld::ComboBox > mxLbODFRecalcOptions
Definition: tpformula.hxx:82
DECL_LINK(SepInsertTextHdl, OUString &, bool)
virtual bool FillItemSet(SfxItemSet *rCoreSet) override
Definition: tpformula.cxx:261
std::unique_ptr< weld::Button > mxBtnCustomCalcDetails
Definition: tpformula.hxx:74
void OnFocusSeparatorInput(weld::Entry *pEdit)
Definition: tpformula.cxx:95
ScDocOptions maCurrentDocOptions
Definition: tpformula.hxx:65
void LaunchCustomCalcSettings()
Definition: tpformula.cxx:123
std::unique_ptr< weld::Entry > mxEdSepFuncArg
Definition: tpformula.hxx:76
std::unique_ptr< weld::CheckButton > mxCbEnglishFuncName
Definition: tpformula.hxx:70
std::unique_ptr< weld::ComboBox > mxLbOOXMLRecalcOptions
Definition: tpformula.hxx:81
std::unique_ptr< weld::Entry > mxEdSepArrayRow
Definition: tpformula.hxx:78
ScDocOptions maSavedDocOptions
Definition: tpformula.hxx:64
virtual void Reset(const SfxItemSet *rCoreSet) override
Definition: tpformula.cxx:325
std::unique_ptr< weld::RadioButton > mxBtnCustomCalcDefault
Definition: tpformula.hxx:72
OUString maOldSepValue
Stores old separator value of currently focused separator edit box.
Definition: tpformula.hxx:59
Configuration options for formula interpreter.
Definition: calcconfig.hxx:44
DeactivateRC
sal_uInt16 sal_Unicode