default values for tooltips

same policy as the tooltips in desktop style
This commit is contained in:
Marco Martin 2018-11-28 13:02:38 +01:00
parent 030159571c
commit 2880333aab

View File

@ -21,6 +21,7 @@
import QtQuick 2.6
import QtQuick.Templates @QQC2_VERSION@ as T
import org.kde.plasma.core 2.0 as PlasmaCore
import org.kde.kirigami 2.5 as Kirigami
T.ToolTip {
id: control
@ -28,6 +29,10 @@ T.ToolTip {
x: parent ? (parent.width - implicitWidth) / 2 : 0
y: -implicitHeight - 3
visible: Kirigami.Settings.tabletMode ? parent.pressed : parent.hovered
delay: Kirigami.Settings.tabletMode ? Qt.styleHints.mousePressAndHoldInterval : 1000
timeout: 5000
implicitWidth: contentItem.implicitWidth + leftPadding + rightPadding
implicitHeight: contentItem.implicitHeight + topPadding + bottomPadding