Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Toggle main menu visibility
Loading...
Searching...
No Matches
qfontdialog_p.h
Go to the documentation of this file.
1
// Copyright (C) 2016 The Qt Company Ltd.
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
// Qt-Security score:significant reason:default
4
5
#
ifndef
QFONTDIALOG_P_H
6
#
define
QFONTDIALOG_P_H
7
8
//
9
// W A R N I N G
10
// -------------
11
//
12
// This file is not part of the Qt API. It exists purely as an
13
// implementation detail. This header file may change from version to
14
// version without notice, or even be removed.
15
//
16
// We mean it.
17
//
18
//
19
20
#
include
<
QtWidgets
/
private
/
qtwidgetsglobal_p
.
h
>
21
#
include
"private/qdialog_p.h"
22
#
include
"qfontdatabase.h"
23
#
include
"qfontdialog.h"
24
#
include
<
qpa
/
qplatformdialoghelper
.
h
>
25
26
#
include
<
QtCore
/
qpointer
.
h
>
27
#
include
"qsharedpointer.h"
28
29
QT_REQUIRE_CONFIG
(
fontdialog
);
30
31
QT_BEGIN_NAMESPACE
32
33
class
QBoxLayout;
34
class
QCheckBox;
35
class
QComboBox;
36
class
QDialogButtonBox;
37
class
QFontListView
;
38
class
QGroupBox;
39
class
QLabel;
40
class
QLineEdit;
41
42
class
Q_AUTOTEST_EXPORT
QFontDialogPrivate
:
public
QDialogPrivate
43
{
44
Q_DECLARE_PUBLIC(QFontDialog)
45
46
public
:
47
QFontDialogPrivate();
48
~QFontDialogPrivate();
49
50
QPlatformFontDialogHelper *platformFontDialogHelper()
const
51
{
return
static_cast
<QPlatformFontDialogHelper *>(platformHelper()); }
52
53
void
updateFamilies();
54
void
updateStyles();
55
void
updateSizes();
56
57
static
QFont getFont(
bool
*ok,
const
QFont &initial, QWidget *parent,
58
const
QString &title, QFontDialog::FontDialogOptions options);
59
60
void
init();
61
void
sizeChanged(
const
QString &);
62
void
familyHighlighted(
int
);
63
void
writingSystemHighlighted(
int
);
64
void
styleHighlighted(
int
);
65
void
sizeHighlighted(
int
);
66
void
updateSample();
67
void
updateSampleFont(
const
QFont &newFont);
68
void
retranslateStrings();
69
70
QLabel *familyAccel;
71
QLineEdit *familyEdit;
72
QFontListView *familyList;
73
74
QLabel *styleAccel;
75
QLineEdit *styleEdit;
76
QFontListView *styleList;
77
78
QLabel *sizeAccel;
79
QLineEdit *sizeEdit;
80
QFontListView *sizeList;
81
82
QGroupBox *effects;
83
QCheckBox *strikeout;
84
QCheckBox *underline;
85
QComboBox *color;
86
87
QGroupBox *sample;
88
QLineEdit *sampleEdit;
89
90
QLabel *writingSystemAccel;
91
QComboBox *writingSystemCombo;
92
93
QBoxLayout *buttonLayout;
94
QBoxLayout *effectsLayout;
95
QBoxLayout *sampleLayout;
96
QBoxLayout *sampleEditLayout;
97
98
QDialogButtonBox *buttonBox;
99
100
QString family;
101
QFontDatabase::WritingSystem writingSystem;
102
QString style;
103
int
size;
104
bool
smoothScalable;
105
QFont selectedFont;
106
QSharedPointer<QFontDialogOptions> options;
107
QPointer<QObject> receiverToDisconnectOnClose;
108
QByteArray memberToDisconnectOnClose;
109
110
bool
canBeNativeDialog()
const
override;
111
void
setVisible(
bool
visible) override;
112
void
_q_runNativeAppModalPanel();
113
114
bool
optionsExplicitlySet =
false
;
115
116
private
:
117
virtual
void
initHelper(QPlatformDialogHelper *) override;
118
virtual
void
helperPrepareShow(QPlatformDialogHelper *) override;
119
};
120
121
QT_END_NAMESPACE
122
123
#
endif
// QFONTDIALOG_P_H
QFontDialogPrivate
Definition
qfontdialog_p.h:43
QFontDialog
\inmodule QtWidgets
Definition
qfontdialog.h:21
QFontListView
Definition
qfontdialog.cpp:34
QFontListView::model
QStringListModel * model() const
Definition
qfontdialog.cpp:38
QFontListView::count
int count() const
Definition
qfontdialog.cpp:47
QFontListView::setCurrentItem
void setCurrentItem(int item)
Definition
qfontdialog.cpp:41
QFontListView::currentChanged
void currentChanged(const QModelIndex ¤t, const QModelIndex &previous) override
This slot is called when a new item becomes the current item.
Definition
qfontdialog.cpp:54
QFontListView::currentText
QString currentText() const
Definition
qfontdialog.cpp:50
QFontListView::currentItem
int currentItem() const
Definition
qfontdialog.cpp:44
QFontListView::text
QString text(int i) const
Definition
qfontdialog.cpp:59
QFontPolishFilter
Definition
qfontdialog.cpp:119
QFontPolishFilter::QFontPolishFilter
QFontPolishFilter(QFontDialog *fd)
Definition
qfontdialog.cpp:121
QFontPolishFilter::eventFilter
bool eventFilter(QObject *obj, QEvent *event) override
Filters events if this object has been installed as an event filter for the watched object.
Definition
qfontdialog.cpp:126
QPainter::QWidget
friend class QWidget
Definition
qpainter.h:432
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qsequentialanimationgroup.cpp:47
qfd_DefaultWindowFlags
static const Qt::WindowFlags qfd_DefaultWindowFlags
Definition
qfontdialog.cpp:73
QT_REQUIRE_CONFIG
QT_REQUIRE_CONFIG(liburing)
qtbase
src
widgets
dialogs
qfontdialog_p.h
Generated on
for Qt by
1.18.0