KDStateMachineEditor API Documentation  1.2.9
A framework for creating Qt State Machine metacode using a graphical user interface
layoutproperties.h
1 /*
2  This file is part of the KDAB State Machine Editor Library.
3 
4  SPDX-FileCopyrightText: 2014-2021 Klarälvdalens Datakonsult AB, a KDAB Group company <info@kdab.com>
5  Author: Kevin Funk <kevin.funk@kdab.com>
6 
7  SPDX-License-Identifier: LGPL-2.1-only OR LicenseRef-KDAB-KDStateMachineEditor
8 
9  Licensees holding valid commercial KDAB State Machine Editor Library
10  licenses may use this file in accordance with the KDAB State Machine Editor
11  Library License Agreement provided with the Software.
12 
13  Contact info@kdab.com if any conditions of this licensing are not clear to you.
14 */
15 
16 #ifndef KDSME_LAYOUT_LAYOUTPROPERTIES_H
17 #define KDSME_LAYOUT_LAYOUTPROPERTIES_H
18 
19 #include "kdsme_core_export.h"
20 
21 #include <QFont>
22 #include <QObject>
23 #include <QRectF>
24 #include <QVariant>
25 
26 namespace KDSME {
27 
28 class KDSME_CORE_EXPORT LayoutProperties : public QObject
29 {
30  Q_OBJECT
31  Q_PROPERTY(qreal regionMargins READ regionMargins WRITE setRegionMargins NOTIFY regionMarginsChanged FINAL)
32  Q_PROPERTY(QFont regionLabelFont READ regionLabelFont WRITE setRegionLabelFont NOTIFY regionLabelFontChanged FINAL)
33  Q_PROPERTY(qreal regionLabelMargins READ regionLabelMargins WRITE setRegionLabelMargins NOTIFY regionLabelMarginsChanged FINAL)
34  Q_PROPERTY(QSizeF regionLabelButtonBoxSize READ regionLabelButtonBoxSize WRITE setRegionLabelButtonBoxSize NOTIFY regionLabelButtonBoxSizeChanged FINAL)
35  Q_PROPERTY(bool showTransitionLabels READ showTransitionLabels WRITE setShowTransitionLabels NOTIFY showTransitionLabelsChanged FINAL)
36 
37 public:
38  explicit LayoutProperties(QObject* parent = nullptr);
40 
41  qreal regionMargins() const;
42  void setRegionMargins(qreal margins);
43 
44  QFont regionLabelFont() const;
45  void setRegionLabelFont(const QFont& font);
46 
47  qreal regionLabelMargins() const;
48  void setRegionLabelMargins(qreal margins);
49 
50  QSizeF regionLabelButtonBoxSize() const;
51  void setRegionLabelButtonBoxSize(const QSizeF& size);
52 
53  bool showTransitionLabels() const;
54  void setShowTransitionLabels(bool show);
55 
56 Q_SIGNALS:
57  void regionMarginsChanged(qreal);
58  void regionLabelFontChanged(const QFont&);
59  void regionLabelMarginsChanged(qreal);
60  void regionLabelButtonBoxSizeChanged(const QSizeF&);
61  void showTransitionLabelsChanged(bool);
62  void changed();
63 
64 private:
65  struct Private;
67 };
68 
69 }
70 
71 #endif // LAYOUTPROPERTIES_H
Definition: layoutproperties.h:28
Definition: mainwindow.h:21

Klarälvdalens Datakonsult AB (KDAB)
"The Qt, C++ and OpenGL Experts"
https://www.kdab.com/
KDStateMachineEditor
Create Qt State Machine metacode using a graphical user interface
https://github.com/KDAB/KDStateMachineEditor