blob: f60ff1b0683f6ef21bf3dbbccc761bff8291a9f7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
import QtQuick 1.0
Item {
id: colorWidget
width: parent.width; height: 16
property variant targetColor
property alias text: flatText.text
Rectangle {
height: 2
anchors {
left: parent.left; right: flatSet.right
bottom: parent.bottom
rightMargin: flatSet.width/2
}
color: colorWidget.targetColor.color
}
Text {
id: flatText
anchors { top: parent.top; left: parent.left }
text:"Color"
color: "white"
}
BlenderToggle {
id: flatSet
width: 32
anchors { right: parent.right }
height: parent.height
buttonText: "Set"
radius: 6
onClicked: {
colorPicker.setTarget(colorWidget.targetColor);
colorPicker.visible = true
}
}
}
|