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 #ifndef INCLUDED_SC_SOURCE_UI_INC_TPFORMULA_HXX
21 #define INCLUDED_SC_SOURCE_UI_INC_TPFORMULA_HXX
22 
23 #include <sfx2/tabdlg.hxx>
24 
25 #include <calcconfig.hxx>
26 #include <docoptio.hxx>
27 
29 {
30 public:
31  explicit ScTpFormulaOptions(weld::Container* pPage, weld::DialogController* pController,
32  const SfxItemSet& rCoreSet);
33  static std::unique_ptr<SfxTabPage>
34  Create(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet* rCoreSet);
35  virtual ~ScTpFormulaOptions() override;
36 
37  virtual bool FillItemSet(SfxItemSet* rCoreSet) override;
38  virtual void Reset(const SfxItemSet* rCoreSet) override;
39  virtual DeactivateRC DeactivatePage(SfxItemSet* pSet) override;
40 
41 private:
42  void ResetSeparators();
44  void UpdateCustomCalcRadioButtons(bool bDefault);
46 
47  bool IsValidSeparator(const OUString& rSep) const;
48 
49  DECL_LINK(ButtonHdl, weld::Button&, 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 
56 private:
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 #endif
86 
87 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
bool IsValidSeparator(const OUString &rSep) const
Definition: tpformula.cxx:132
sal_Unicode mnDecSep
Definition: tpformula.hxx:67
ScCalcConfig maSavedConfig
Definition: tpformula.hxx:61
virtual bool FillItemSet(SfxItemSet *rCoreSet) override
Definition: tpformula.cxx:221
const SfxItemSet * pSet
std::unique_ptr< weld::RadioButton > mxBtnCustomCalcDefault
Definition: tpformula.hxx:72
ScDocOptions maSavedDocOptions
Definition: tpformula.hxx:64
std::unique_ptr< weld::Button > mxBtnSepReset
Definition: tpformula.hxx:79
std::unique_ptr< weld::RadioButton > mxBtnCustomCalcCustom
Definition: tpformula.hxx:73
sal_uInt16 sal_Unicode
std::unique_ptr< weld::CheckButton > mxCbEnglishFuncName
Definition: tpformula.hxx:70
std::unique_ptr< weld::Entry > mxEdSepFuncArg
Definition: tpformula.hxx:76
std::unique_ptr< weld::ComboBox > mxLbODFRecalcOptions
Definition: tpformula.hxx:82
void LaunchCustomCalcSettings()
Definition: tpformula.cxx:122
std::unique_ptr< weld::Entry > mxEdSepArrayCol
Definition: tpformula.hxx:77
ScCalcConfig maCurrentConfig
Definition: tpformula.hxx:62
virtual void Reset(const SfxItemSet *rCoreSet) override
Definition: tpformula.cxx:285
Configuration options for formula interpreter.
Definition: calcconfig.hxx:44
std::unique_ptr< weld::ComboBox > mxLbFormulaSyntax
Definition: tpformula.hxx:69
ScDocOptions maCurrentDocOptions
Definition: tpformula.hxx:65
std::unique_ptr< weld::Entry > mxEdSepArrayRow
Definition: tpformula.hxx:78
virtual ~ScTpFormulaOptions() override
Definition: tpformula.cxx:81
void OnFocusSeparatorInput(weld::Entry *pEdit)
Definition: tpformula.cxx:94
void UpdateCustomCalcRadioButtons(bool bDefault)
Definition: tpformula.cxx:106
ScTpFormulaOptions(weld::Container *pPage, weld::DialogController *pController, const SfxItemSet &rCoreSet)
Definition: tpformula.cxx:34
void ResetSeparators()
Definition: tpformula.cxx:85
DeactivateRC
DECL_LINK(ButtonHdl, weld::Button &, void)
std::unique_ptr< weld::ComboBox > mxLbOOXMLRecalcOptions
Definition: tpformula.hxx:81
virtual DeactivateRC DeactivatePage(SfxItemSet *pSet) override
Definition: tpformula.cxx:367
OUString maOldSepValue
Stores old separator value of currently focused separator edit box.
Definition: tpformula.hxx:59
std::unique_ptr< weld::Button > mxBtnCustomCalcDetails
Definition: tpformula.hxx:74
static std::unique_ptr< SfxTabPage > Create(weld::Container *pPage, weld::DialogController *pController, const SfxItemSet *rCoreSet)
Definition: tpformula.cxx:216