aboutsummaryrefslogtreecommitdiffstats
path: root/tools/balsamui/settingstab.h
blob: c55b8a2b1115b2ff5dd77e91897318448955ebed (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
// Copyright (C) 2021 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0

#ifndef SETTINGSTAB_H
#define SETTINGSTAB_H

#include <QString>
#include <QScrollArea>
#include <QVariantMap>

QT_BEGIN_NAMESPACE
class QWidget;
QT_END_NAMESPACE

struct Setting
{
    QWidget *uiELement = nullptr;
    QString name;
    bool defaultBool = false;
    double defaultReal = 0.0;
};

class SettingsTab : public QScrollArea
{
    Q_OBJECT

public:
    explicit SettingsTab(QWidget *parent = nullptr);

    QJsonObject getOptions() const;

private:
    QList<Setting> settings;
};

#endif