Maki
Formally verfied low-code orchestration
Loading...
Searching...
No Matches
app_configs.h
1#pragma once
2
3#include <QColor>
4#include <QFont>
5#include <QSize>
6#include <QString>
7
8namespace Config
9{
10using namespace Qt::StringLiterals;
11
13static const QString ORGANIZATION_NAME = QString("Savant"_L1);
14static const QString APPLICATION_NAME = QString("MAKI"_L1);
15static const QString VERSION = QString("0.0.1"_L1);
16
17static const QString MAIN_CANVAS = QString("MainSystemCanvas"_L1);
18
19static const int GRID_SIZE = 20;
20static const int CONNECTOR_RADIUS = 5;
21static const qreal MINIMUM_NODE_SIZE = 50;
22static const qreal OPACITY_THRESHOLD = 0.25;
23
24static const int MENU_WIDTH = 280;
25static const int LONG_LABEL_WIDTH = 85;
26static const int SHORT_LABEL_WIDTH = 75;
27static const int CONTENT_PADDING = 5;
28static const int SMALL_BUTTON = 16;
29static const QSize SMALL_BUTTON_SIZE = {SMALL_BUTTON, SMALL_BUTTON};
30static const int MEDIUM_SMALL_BUTTON = 24;
31static const QSize MEDIUM_SMALL_BUTTON_SIZE = {MEDIUM_SMALL_BUTTON, MEDIUM_SMALL_BUTTON};
32static const int MEDIUM_BUTTON = 30;
33static const QSize MEDIUM_BUTTON_SIZE = {MEDIUM_BUTTON, MEDIUM_BUTTON};
34
35extern QColor FOREGROUND;
36extern QColor HIGHLIGHT;
37extern QColor HOVER;
38
39enum class ControlPosition
40{
41 Top,
42 Bottom,
43 Left,
44 Right
45};
46} // namespace Config
47
48namespace Constants
49{
51static const QString TMP_CONNECTION_ID = QStringLiteral("tmp_id");
52static const QString TYPE_NODE = QStringLiteral("application/x-node");
53static const QString TYPE_PIXMAP = QStringLiteral("application/x-pixmap");
54static const QString TYPE_CONFIG = QStringLiteral("application/x-configuration");
55static const QString TYPE_NODE_ID = QStringLiteral("application/x-node-id");
56static const QString MAIN_FLOW = "main";
57
58static const qreal CONTROL_POINT_SHIFT = 100;
59
60static const QString EMPTY_COMBO = "-";
61static const int TOOLTIP_DURATION = 2;
62} // namespace Constants
63
64class Fonts
65{
66public:
68 static const QFont Main;
69 static const QFont Property;
70 static const QFont Label;
71 static const QFont Hint;
72 static const QFont SmallTab;
73 static const QFont MonoSpace;
74
76 static constexpr float MaxSize = 10000.0;
77
79 static constexpr float BaseSize = 10.0;
80
82 static constexpr float BaseFactor = 20.0;
83};
Definition app_configs.h:65
static const QFont Property
Main font.
Definition app_configs.h:69
static constexpr float MaxSize
Monospace font.
Definition app_configs.h:76
static const QFont SmallTab
Hint font.
Definition app_configs.h:72
static const QFont MonoSpace
Small tab font.
Definition app_configs.h:73
static const QFont Main
Font constants for the application.
Definition app_configs.h:68
static const QFont Label
Property font.
Definition app_configs.h:70
static const QFont Hint
Label font.
Definition app_configs.h:71
static constexpr float BaseSize
Base size for fonts.
Definition app_configs.h:79
static constexpr float BaseFactor
Base factor for font scaling.
Definition app_configs.h:82