1 | /* |
2 | SPDX-FileCopyrightText: 2001-2013 Evan Teran <evan.teran@gmail.com> |
3 | SPDX-FileCopyrightText: 1996-2000 Bernd Johannes Wuebben <wuebben@kde.org> |
4 | |
5 | SPDX-License-Identifier: GPL-2.0-or-later |
6 | */ |
7 | |
8 | #pragma once |
9 | |
10 | #include "kcalc_button.h" |
11 | |
12 | struct science_constant; |
13 | |
14 | class KCalcConstButton : public KCalcButton |
15 | { |
16 | Q_OBJECT |
17 | |
18 | public: |
19 | explicit KCalcConstButton(QWidget *parent); |
20 | |
21 | KCalcConstButton(const QString &label, QWidget *parent, const QString &tooltip = QString()); |
22 | |
23 | QString constant() const; |
24 | |
25 | void setButtonNumber(int num); |
26 | |
27 | void setLabelAndTooltip(); |
28 | |
29 | Q_SIGNALS: |
30 | void constButtonClicked(int num); |
31 | |
32 | private Q_SLOTS: |
33 | void slotConfigureButton(); |
34 | void slotChooseScientificConst(const science_constant &const_chosen); |
35 | void slotClicked(); |
36 | |
37 | private: |
38 | void (); |
39 | |
40 | private: |
41 | int button_num_ = -1; |
42 | }; |
43 | |
44 | |