LibreOffice Module sc (master)  1
filldlg.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_FILLDLG_HXX
21 #define INCLUDED_SC_SOURCE_UI_INC_FILLDLG_HXX
22 
23 #include <vcl/weld.hxx>
24 #include <global.hxx>
25 
26 class ScDocument;
27 
29 {
30 public:
31  ScFillSeriesDlg( weld::Window* pParent,
32  ScDocument& rDocument,
33  FillDir eFillDir,
34  FillCmd eFillCmd,
35  FillDateCmd eFillDateCmd,
36  const OUString& aStartStr,
37  double fStep,
38  double fMax,
39  SCSIZE nSelectHeight,
40  SCSIZE nSelectWidth,
41  sal_uInt16 nPossDir );
42  virtual ~ScFillSeriesDlg() override;
43 
44  FillDir GetFillDir() const { return theFillDir; }
45  FillCmd GetFillCmd() const { return theFillCmd; }
47  double GetStart() const { return fStartVal; }
48  double GetStep() const { return fIncrement; }
49  double GetMax() const { return fEndVal; }
50 
51  OUString GetStartStr() const { return m_xEdStartVal->get_text(); }
52 
53  void SetEdStartValEnabled(bool bFlag);
54 
55 private:
56  const OUString aStartStrVal;
57  const OUString aErrMsgInvalidVal;
58 
63  double fStartVal;
64  double fIncrement;
65  double fEndVal;
68 
69  std::unique_ptr<weld::Label> m_xFtStartVal;
70  std::unique_ptr<weld::Entry> m_xEdStartVal;
71 
72  std::unique_ptr<weld::Label> m_xFtEndVal;
73  std::unique_ptr<weld::Entry> m_xEdEndVal;
74 
75  std::unique_ptr<weld::Label> m_xFtIncrement;
76  std::unique_ptr<weld::Entry> m_xEdIncrement;
77  std::unique_ptr<weld::RadioButton> m_xBtnDown;
78  std::unique_ptr<weld::RadioButton> m_xBtnRight;
79  std::unique_ptr<weld::RadioButton> m_xBtnUp;
80  std::unique_ptr<weld::RadioButton> m_xBtnLeft;
81 
82  std::unique_ptr<weld::RadioButton> m_xBtnArithmetic;
83  std::unique_ptr<weld::RadioButton> m_xBtnGeometric;
84  std::unique_ptr<weld::RadioButton> m_xBtnDate;
85  std::unique_ptr<weld::RadioButton> m_xBtnAutoFill;
86 
87  std::unique_ptr<weld::Label> m_xFtTimeUnit;
88  std::unique_ptr<weld::RadioButton> m_xBtnDay;
89  std::unique_ptr<weld::RadioButton> m_xBtnDayOfWeek;
90  std::unique_ptr<weld::RadioButton> m_xBtnMonth;
91  std::unique_ptr<weld::RadioButton> m_xBtnYear;
92 
93  std::unique_ptr<weld::Button> m_xBtnOk;
94 
95  void Init( sal_uInt16 nPossDir );
97 
98  DECL_LINK(OKHdl, weld::Button&, void);
99  DECL_LINK(DisableHdl, weld::ToggleButton&, void);
100 };
101 
102 #endif // INCLUDED_SC_SOURCE_UI_INC_FILLDLG_HXX
103 
104 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
std::unique_ptr< weld::RadioButton > m_xBtnDown
Definition: filldlg.hxx:77
double fIncrement
Definition: filldlg.hxx:64
std::unique_ptr< weld::RadioButton > m_xBtnUp
Definition: filldlg.hxx:79
std::unique_ptr< weld::Label > m_xFtStartVal
Definition: filldlg.hxx:69
std::unique_ptr< weld::Entry > m_xEdIncrement
Definition: filldlg.hxx:76
FillDir
Definition: global.hxx:320
std::unique_ptr< weld::Entry > m_xEdEndVal
Definition: filldlg.hxx:73
ScDocument & rDoc
Definition: filldlg.hxx:59
FillCmd theFillCmd
Definition: filldlg.hxx:61
double GetStart() const
Definition: filldlg.hxx:47
void Init(sal_uInt16 nPossDir)
Definition: filldlg.cxx:97
FillDir GetFillDir() const
Definition: filldlg.hxx:44
const OUString aErrMsgInvalidVal
Definition: filldlg.hxx:57
FillDateCmd GetFillDateCmd() const
Definition: filldlg.hxx:46
size_t SCSIZE
size_t typedef to be able to find places where code was changed from USHORT to size_t and is used to ...
Definition: address.hxx:45
FillDateCmd
Definition: global.hxx:345
weld::Entry * CheckValues()
Definition: filldlg.cxx:181
const OUString aStartStrVal
Definition: filldlg.hxx:56
std::unique_ptr< weld::RadioButton > m_xBtnDay
Definition: filldlg.hxx:88
FillCmd
Definition: global.hxx:328
std::unique_ptr< weld::Label > m_xFtTimeUnit
Definition: filldlg.hxx:87
void SetEdStartValEnabled(bool bFlag)
Definition: filldlg.cxx:83
std::unique_ptr< weld::RadioButton > m_xBtnArithmetic
Definition: filldlg.hxx:82
std::unique_ptr< weld::RadioButton > m_xBtnDayOfWeek
Definition: filldlg.hxx:89
std::unique_ptr< weld::RadioButton > m_xBtnRight
Definition: filldlg.hxx:78
std::unique_ptr< weld::Button > m_xBtnOk
Definition: filldlg.hxx:93
const SCSIZE m_nSelectWidth
Definition: filldlg.hxx:67
OUString GetStartStr() const
Definition: filldlg.hxx:51
const SCSIZE m_nSelectHeight
Definition: filldlg.hxx:66
std::unique_ptr< weld::RadioButton > m_xBtnMonth
Definition: filldlg.hxx:90
std::unique_ptr< weld::RadioButton > m_xBtnGeometric
Definition: filldlg.hxx:83
double GetMax() const
Definition: filldlg.hxx:49
double fStartVal
Definition: filldlg.hxx:63
FillDateCmd theFillDateCmd
Definition: filldlg.hxx:62
double GetStep() const
Definition: filldlg.hxx:48
double fEndVal
Definition: filldlg.hxx:65
FillDir theFillDir
Definition: filldlg.hxx:60
std::unique_ptr< weld::RadioButton > m_xBtnAutoFill
Definition: filldlg.hxx:85
std::unique_ptr< weld::RadioButton > m_xBtnYear
Definition: filldlg.hxx:91
std::unique_ptr< weld::RadioButton > m_xBtnLeft
Definition: filldlg.hxx:80
std::unique_ptr< weld::Entry > m_xEdStartVal
Definition: filldlg.hxx:70
FillCmd GetFillCmd() const
Definition: filldlg.hxx:45
DECL_LINK(OKHdl, weld::Button &, void)
std::unique_ptr< weld::Label > m_xFtIncrement
Definition: filldlg.hxx:75
virtual ~ScFillSeriesDlg() override
Definition: filldlg.cxx:79
std::unique_ptr< weld::RadioButton > m_xBtnDate
Definition: filldlg.hxx:84
std::unique_ptr< weld::Label > m_xFtEndVal
Definition: filldlg.hxx:72
ScFillSeriesDlg(weld::Window *pParent, ScDocument &rDocument, FillDir eFillDir, FillCmd eFillCmd, FillDateCmd eFillDateCmd, const OUString &aStartStr, double fStep, double fMax, SCSIZE nSelectHeight, SCSIZE nSelectWidth, sal_uInt16 nPossDir)
Definition: filldlg.cxx:33