Debian Codegraph @

tests/manual/scenegraph_lancelot/data/shape/shape_spread.qml

raw
1 import QtQuick 2.9
2 import QtQuick.Shapes 1.0
3
4 Item {
5 width: 320
6 height: 480
7
8 Column {
9 Repeater {
10 model: 3
11 Shape {
12 vendorExtensionsEnabled: false
13 width: 200
14 height: 150
15 ShapePath {
16 strokeColor: "transparent"
17
18 fillGradient: LinearGradient {
19 id: grad
20 y1: 50; y2: 80
21 spread: model.index === 0 ? ShapeGradient.PadSpread : (model.index === 1 ? ShapeGradient.RepeatSpread : ShapeGradient.ReflectSpread)
22 GradientStop { position: 0; color: "black" }
23 GradientStop { position: 1; color: "red" }
24 }
25
26 startX: 10; startY: 10
27 PathLine { relativeX: 180; relativeY: 0 }
28 PathLine { relativeX: 0; relativeY: 100 }
29 PathLine { relativeX: -180; relativeY: 0 }
30 PathLine { relativeX: 0; relativeY: -100 }
31 }
32 }
33 }
34 }
35 }