tdf#130857 qt weld: Implement QtInstanceWidget::strip_mnemonic
[LibreOffice.git] / sc / source / ui / inc / filldlg.hxx
blob8c8203746526d9cedf99f2ebbc78f058e6ba1d43
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/.
9 * This file incorporates work covered by the following license notice:
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 .
20 #pragma once
22 #include <vcl/weld.hxx>
23 #include <global.hxx>
25 class ScDocument;
27 class ScFillSeriesDlg : public weld::GenericDialogController
29 public:
30 ScFillSeriesDlg( weld::Window* pParent,
31 ScDocument& rDocument,
32 FillDir eFillDir,
33 FillCmd eFillCmd,
34 FillDateCmd eFillDateCmd,
35 OUString aStartStr,
36 double fStep,
37 double fMax,
38 SCSIZE nSelectHeight,
39 SCSIZE nSelectWidth,
40 sal_uInt16 nPossDir );
41 virtual ~ScFillSeriesDlg() override;
43 FillDir GetFillDir() const { return theFillDir; }
44 FillCmd GetFillCmd() const { return theFillCmd; }
45 FillDateCmd GetFillDateCmd() const { return theFillDateCmd; }
46 double GetStart() const { return fStartVal; }
47 double GetStep() const { return fIncrement; }
48 double GetMax() const { return fEndVal; }
50 OUString GetStartStr() const { return m_xEdStartVal->get_text(); }
52 void SetEdStartValEnabled(bool bFlag);
54 private:
55 const OUString aStartStrVal;
56 const OUString aErrMsgInvalidVal;
58 ScDocument& rDoc;
59 FillDir theFillDir;
60 FillCmd theFillCmd;
61 FillDateCmd theFillDateCmd;
62 double fStartVal;
63 double fIncrement;
64 double fEndVal;
65 const SCSIZE m_nSelectHeight;
66 const SCSIZE m_nSelectWidth;
68 std::unique_ptr<weld::Label> m_xFtStartVal;
69 std::unique_ptr<weld::Entry> m_xEdStartVal;
71 std::unique_ptr<weld::Label> m_xFtEndVal;
72 std::unique_ptr<weld::Entry> m_xEdEndVal;
74 std::unique_ptr<weld::Label> m_xFtIncrement;
75 std::unique_ptr<weld::Entry> m_xEdIncrement;
76 std::unique_ptr<weld::RadioButton> m_xBtnDown;
77 std::unique_ptr<weld::RadioButton> m_xBtnRight;
78 std::unique_ptr<weld::RadioButton> m_xBtnUp;
79 std::unique_ptr<weld::RadioButton> m_xBtnLeft;
81 std::unique_ptr<weld::RadioButton> m_xBtnArithmetic;
82 std::unique_ptr<weld::RadioButton> m_xBtnGeometric;
83 std::unique_ptr<weld::RadioButton> m_xBtnDate;
84 std::unique_ptr<weld::RadioButton> m_xBtnAutoFill;
86 std::unique_ptr<weld::Label> m_xFtTimeUnit;
87 std::unique_ptr<weld::RadioButton> m_xBtnDay;
88 std::unique_ptr<weld::RadioButton> m_xBtnDayOfWeek;
89 std::unique_ptr<weld::RadioButton> m_xBtnMonth;
90 std::unique_ptr<weld::RadioButton> m_xBtnYear;
92 std::unique_ptr<weld::Button> m_xBtnOk;
94 void Init( sal_uInt16 nPossDir );
95 weld::Entry* CheckValues();
97 DECL_LINK(OKHdl, weld::Button&, void);
98 DECL_LINK(DisableHdl, weld::Toggleable&, void);
101 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */