BibleTime
btfontsettings.h
Go to the documentation of this file.
1 /*********
2 *
3 * In the name of the Father, and of the Son, and of the Holy Spirit.
4 *
5 * This file is part of BibleTime's source code, https://bibletime.info/
6 *
7 * Copyright 1999-2021 by the BibleTime developers.
8 * The BibleTime source code is licensed under the GNU General Public License
9 * version 2.0.
10 *
11 **********/
12 
13 #pragma once
14 
15 #include "btconfigdialog.h"
16 
17 #include <QObject>
18 #include <QString>
19 #include <vector>
20 #include "../../backend/config/btconfig.h"
21 
22 
24 class Language;
25 class QCheckBox;
26 class QComboBox;
27 class QFontDialog;
28 class QGroupBox;
29 class QLabel;
30 
32 
33  Q_OBJECT
34 
35  private: // types:
36 
37  struct WorkSetting {
38  Language const & language;
40  };
41 
42  public: // methods:
43 
44  BtFontSettingsPage(CConfigurationDialog *parent = nullptr);
45 
46  void save() const final override;
47 
48  protected Q_SLOTS:
49 
50  // This slot is called when the "Use own font for language" button was clicked.
51  void useOwnFontClicked(bool);
52 
53  private: // methods:
54 
55  void retranslateUi();
56 
57  private: // fields:
58 
59  QGroupBox *m_fontsGroupBox;
60  QLabel *m_languageLabel;
62  QCheckBox *m_languageCheckBox;
63  QFontDialog * m_fontChooser;
64 
66 
67 };
QPair< bool, QFont > FontSettingsPair
Definition: btconfig.h:47
BtFontSettingsPage(CConfigurationDialog *parent=nullptr)
QGroupBox * m_fontsGroupBox
std::vector< WorkSetting > m_workSettings
void useOwnFontClicked(bool)
QComboBox * m_languageComboBox
QCheckBox * m_languageCheckBox
QLabel * m_languageLabel
QFontDialog * m_fontChooser
void save() const final override
BtConfig::FontSettingsPair settings