aboutsummaryrefslogtreecommitdiffstats
path: root/src/quicktemplates2/qquickbutton.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/quicktemplates2/qquickbutton.cpp')
-rw-r--r--src/quicktemplates2/qquickbutton.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/quicktemplates2/qquickbutton.cpp b/src/quicktemplates2/qquickbutton.cpp
index 1a614754..9cbf8b21 100644
--- a/src/quicktemplates2/qquickbutton.cpp
+++ b/src/quicktemplates2/qquickbutton.cpp
@@ -57,6 +57,10 @@ QT_BEGIN_NAMESPACE
a question. Typical buttons are \e OK, \e Apply, \e Cancel, \e Close,
\e Yes, \e No, and \e Help.
+ Button inherits its API from AbstractButton. For instance, you can set
+ \l {AbstractButton::text}{text}, display an \l {Icons in Qt Quick Controls 2}{icon},
+ and react to \l {AbstractButton::clicked}{clicks} using the AbstractButton API.
+
A button emits the signal \l {AbstractButton::}{clicked()} when it is activated by the user.
Connect to this signal to perform the button's action. Buttons also
provide the signals \l {AbstractButton::}{canceled()}, \l {AbstractButton::}{doubleClicked()}, \l {AbstractButton::}{pressed()},
@@ -119,6 +123,11 @@ QFont QQuickButton::defaultFont() const
return QQuickControlPrivate::themeFont(QPlatformTheme::PushButtonFont);
}
+QPalette QQuickButton::defaultPalette() const
+{
+ return QQuickControlPrivate::themePalette(QPlatformTheme::ButtonPalette);
+}
+
/*!
\qmlproperty bool QtQuick.Controls::Button::highlighted