forked from qt-creator/qt-creator
QmlDesigner: Adding tool tips for anchoring
Task-number: QTCREATORBUG-13503 Change-Id: I2c65e47797ba77d3cc2e5b2c6723b1c010982d8f Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
This commit is contained in:
@@ -34,6 +34,7 @@ ButtonRow {
|
||||
|
||||
ButtonRowButton {
|
||||
iconSource: "images/anchor-top.png"
|
||||
tooltip: qsTr("Anchor item to the top.")
|
||||
|
||||
property bool topAnchored: anchorBackend.topAnchored
|
||||
onTopAnchoredChanged: {
|
||||
@@ -53,6 +54,7 @@ ButtonRow {
|
||||
|
||||
ButtonRowButton {
|
||||
iconSource: "images/anchor-bottom.png"
|
||||
tooltip: qsTr("Anchor item to the bottom.")
|
||||
|
||||
property bool bottomAnchored: anchorBackend.bottomAnchored
|
||||
onBottomAnchoredChanged: {
|
||||
@@ -73,6 +75,7 @@ ButtonRow {
|
||||
|
||||
ButtonRowButton {
|
||||
iconSource: "images/anchor-left.png"
|
||||
tooltip: qsTr("Anchor item to the left.")
|
||||
|
||||
property bool leftAnchored: anchorBackend.leftAnchored
|
||||
onLeftAnchoredChanged: {
|
||||
@@ -92,6 +95,7 @@ ButtonRow {
|
||||
|
||||
ButtonRowButton {
|
||||
iconSource: "images/anchor-right.png"
|
||||
tooltip: qsTr("Anchor item to the right.")
|
||||
|
||||
property bool rightAnchored: anchorBackend.rightAnchored
|
||||
onRightAnchoredChanged: {
|
||||
@@ -116,6 +120,7 @@ ButtonRow {
|
||||
|
||||
ButtonRowButton {
|
||||
iconSource: "images/anchor-fill.png"
|
||||
tooltip: qsTr("Fill parent item.")
|
||||
|
||||
property bool isFilled: anchorBackend.isFilled
|
||||
onIsFilledChanged: {
|
||||
@@ -137,6 +142,7 @@ ButtonRow {
|
||||
|
||||
ButtonRowButton {
|
||||
iconSource: "images/anchor-vertical.png"
|
||||
tooltip: qsTr("Anchor item vertically.")
|
||||
|
||||
property bool verticalCentered: anchorBackend.verticalCentered;
|
||||
onVerticalCenteredChanged: {
|
||||
@@ -158,6 +164,7 @@ ButtonRow {
|
||||
|
||||
ButtonRowButton {
|
||||
iconSource: "images/anchor-horizontal.png"
|
||||
tooltip: qsTr("Anchor item horizontally.")
|
||||
|
||||
property bool horizontalCentered: anchorBackend.horizontalCentered;
|
||||
onHorizontalCenteredChanged: {
|
||||
|
@@ -126,6 +126,7 @@ RowLayout {
|
||||
exclusive: true
|
||||
ButtonRowButton {
|
||||
iconSource: verticalAnchor ? "../HelperWidgets/images/anchor-top.png" : "../HelperWidgets/images/anchor-left.png"
|
||||
tooltip: verticalAnchor ? qsTr("Anchor to the top of the target.") : qsTr("Anchor to the left of the target.")
|
||||
onClicked: {
|
||||
if (!invertRelativeTargets)
|
||||
sameEdgeButtonClicked();
|
||||
@@ -136,12 +137,14 @@ RowLayout {
|
||||
|
||||
ButtonRowButton {
|
||||
iconSource: verticalAnchor ? "../HelperWidgets/images/anchor-vertical.png" : "../HelperWidgets/images/anchor-horizontal.png"
|
||||
tooltip: verticalAnchor ? qsTr("Anchor to the vertical center of the target.") : qsTr("Anchor to the horizontal center of the target.")
|
||||
|
||||
onClicked: centerButtonClicked();
|
||||
}
|
||||
|
||||
ButtonRowButton {
|
||||
iconSource: verticalAnchor ? "../HelperWidgets/images/anchor-bottom.png" : "../HelperWidgets/images/anchor-right.png"
|
||||
tooltip: verticalAnchor ? qsTr("Anchor to the bottom of the target.") : qsTr("Anchor to the right of the target.")
|
||||
onClicked: {
|
||||
if (!invertRelativeTargets)
|
||||
oppositeEdgeButtonClicked();
|
||||
|
Reference in New Issue
Block a user