File: gradients.qps

package info (click to toggle)
qtbase-opensource-src 5.15.15%2Bdfsg-6
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 350,700 kB
  • sloc: cpp: 2,089,913; ansic: 336,851; xml: 115,491; python: 9,447; java: 7,499; asm: 4,023; perl: 2,047; sh: 2,037; yacc: 1,687; lex: 1,333; javascript: 878; makefile: 273; objc: 70
file content (44 lines) | stat: -rw-r--r-- 855 bytes parent folder | download | duplicates (19)
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
38
39
40
41
42
43
44
# Version: 1
# CheckVsReference: 5%

drawText 75 20 "Linear"
drawText 176 20 "Radial"
drawText 277 20 "Conical"
translate 0 30
drawText 0 50 "AA off"
drawText 0 151 "AA on"

setPen nopen

gradient_clearStops
gradient_appendStop 0     0x00000000
gradient_appendStop 0.001 red
gradient_appendStop 0.2   blue
gradient_appendStop 0.4   yellow
gradient_appendStop 0.6   cyan
gradient_appendStop 0.8   green
gradient_appendStop 0.999 red
gradient_appendStop 1     0x00000000

gradient_setSpread PadSpread
gradient_setCoordinateMode ObjectBoundingMode

begin_block row
save
gradient_setLinear 0.1 0.0 0.9 0.0
drawRect 50 0 100 100

gradient_setRadial 0.5 0.5 0.5 0.5 0.5
translate 101 0
drawRect 50 0 100 100

gradient_setConical 0.5 0.5 45
translate 101 0
drawRect 50 0 100 100
restore
end_block row

setRenderHint Antialiasing

translate 0 101
repeat_block row