QElectroTech  0.70
qtextorientationspinboxwidget.h
Go to the documentation of this file.
1 /*
2  Copyright 2006-2019 The QElectroTech Team
3  This file is part of QElectroTech.
4 
5  QElectroTech is free software: you can redistribute it and/or modify
6  it under the terms of the GNU General Public License as published by
7  the Free Software Foundation, either version 2 of the License, or
8  (at your option) any later version.
9 
10  QElectroTech is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  GNU General Public License for more details.
14 
15  You should have received a copy of the GNU General Public License
16  along with QElectroTech. If not, see <http://www.gnu.org/licenses/>.
17 */
18 #ifndef Q_TEXT_ORIENTATION_SPINBOX_WIDGET_H
19 #define Q_TEXT_ORIENTATION_SPINBOX_WIDGET_H
20 #include <QtWidgets>
21 #include "qtextorientationwidget.h"
27 class QTextOrientationSpinBoxWidget : public QWidget {
28  Q_OBJECT
29 
30  // constructors, destructor
31  public:
32  QTextOrientationSpinBoxWidget(QWidget * = nullptr);
34  private:
36 
37  signals:
41  void editingFinished(double);
42  void editingFinished();
43 
44  // methods
45  public:
47  QDoubleSpinBox *spinBox() const;
48  double orientation() const;
49  double value() const;
50  bool isReadOnly() const;
51 
52  public slots:
53  void setOrientation(const double &);
54  void setValue(const double &);
55  void setReadOnly(bool);
56 
57  private:
58  void build();
59 
60  private slots:
61  void emitChangeSignals();
62 
63  // attributes
64  private:
66  QDoubleSpinBox *spin_box_;
67 };
68 #endif
QTextOrientationWidget * orientationWidget() const
QTextOrientationWidget * orientation_widget_