1// SPDX-FileCopyrightText: 2023 UnionTech Software Technology Co., Ltd.
2//
3// SPDX-License-Identifier: GPL-3.0-or-later
4
5#ifndef PROFILESETTINGWIDGET_H
6#define PROFILESETTINGWIDGET_H
7
8#include <common/widget/pagewidget.h>
9#include <QMap>
10
11static const QString lNameItem{"name"};
12static const QString lPathItem{"path"};
13
14using LanguagePaths = QMap<QString, QString>;
15class ProfileSettingWidgetPrivate;
16class ProfileSettingWidget : public PageWidget
17{
18 Q_OBJECT
19public:
20 explicit ProfileSettingWidget(QWidget *parent = nullptr);
21 virtual ~ProfileSettingWidget();
22 QString translateFilePath();
23 QString languageFilePath();
24 const LanguagePaths &getLanguagePaths() const;
25
26 void saveConfig() override;
27 void readConfig() override;
28
29private:
30 void setupUi();
31 ProfileSettingWidgetPrivate *const d;
32
33protected:
34 void readTranslate();
35};
36
37#endif // PROFILESETTINGWIDGET_H
38