forked from qt-creator/qt-creator
QmlDesigner: Offset move/scale gizmo label in screen space
Offsetting in scene space resulted in label being inconsistent distance away from the object, depending on zoom and angle. Change-Id: Ief555de664c042bb1a5c93af0ee7e5a1c3e7ce0a Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io> Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
This commit is contained in:
@@ -257,13 +257,12 @@ Window {
|
||||
id: gizmoLabel
|
||||
targetNode: moveGizmo.visible ? moveGizmo : scaleGizmo
|
||||
targetView: overlayView
|
||||
offset: Qt.vector3d(0, 45, 0)
|
||||
visible: targetNode.dragging
|
||||
|
||||
Rectangle {
|
||||
color: "white"
|
||||
x: -width / 2
|
||||
y: -height
|
||||
y: -height - 8
|
||||
width: gizmoLabelText.width + 4
|
||||
height: gizmoLabelText.height + 4
|
||||
border.width: 1
|
||||
|
Reference in New Issue
Block a user