0
|
1 |
|
|
2 |
#setRenderHint SmoothPixmapTransform
|
|
3 |
|
|
4 |
translate 10 50
|
|
5 |
setBackground ff7f7f
|
|
6 |
setPen 3f3f9f
|
|
7 |
|
|
8 |
bitmap_load dome_mono.png the_pixmap
|
|
9 |
|
|
10 |
save
|
|
11 |
# Draw with opaque pen/bg in transparent/opaque mode
|
|
12 |
setBackgroundMode Transparent
|
|
13 |
drawPixmap the_pixmap 0 0
|
|
14 |
setBackgroundMode Opaque
|
|
15 |
drawPixmap the_pixmap 110 0
|
|
16 |
|
|
17 |
translate 220 0
|
|
18 |
|
|
19 |
# Draw with alpha pen/bg in transparent/opaque mode
|
|
20 |
save
|
|
21 |
setBackground 7fff7f7f
|
|
22 |
setPen 7f3f3f9f
|
|
23 |
setBackgroundMode Transparent
|
|
24 |
drawPixmap the_pixmap 0 0
|
|
25 |
setBackgroundMode Opaque
|
|
26 |
drawPixmap the_pixmap 110 0
|
|
27 |
restore
|
|
28 |
|
|
29 |
translate 220 0
|
|
30 |
|
|
31 |
# Draw with rotated opaque pen/bg in transparent/opaque mode
|
|
32 |
setBackgroundMode Transparent
|
|
33 |
save
|
|
34 |
translate 50 50
|
|
35 |
rotate 10
|
|
36 |
translate -50 -50
|
|
37 |
drawPixmap the_pixmap 0 0
|
|
38 |
restore
|
|
39 |
setBackgroundMode Opaque
|
|
40 |
translate 110 0
|
|
41 |
save
|
|
42 |
translate 50 50
|
|
43 |
rotate 10
|
|
44 |
translate -50 -50
|
|
45 |
drawPixmap the_pixmap 0 0
|
|
46 |
restore
|
|
47 |
restore
|
|
48 |
|
|
49 |
translate 0 150
|
|
50 |
|
|
51 |
save
|
|
52 |
setBackgroundMode Transparent
|
|
53 |
drawTiledPixmap the_pixmap 0 0 200 100
|
|
54 |
setBackgroundMode Opaque
|
|
55 |
drawTiledPixmap the_pixmap 210 0 200 100
|
|
56 |
|
|
57 |
translate 440 -10
|
|
58 |
save
|
|
59 |
rotate 10
|
|
60 |
drawTiledPixmap the_pixmap 0 0 200 100
|
|
61 |
restore
|
|
62 |
restore
|
|
63 |
|
|
64 |
translate 0 150
|
|
65 |
save
|
|
66 |
setBackgroundMode Transparent
|
|
67 |
drawTiledPixmap the_pixmap 0 0 200 100 10 20
|
|
68 |
setBackgroundMode Opaque
|
|
69 |
drawTiledPixmap the_pixmap 210 0 200 100 10 20
|
|
70 |
|
|
71 |
translate 440 -10
|
|
72 |
save
|
|
73 |
rotate 10
|
|
74 |
drawTiledPixmap the_pixmap 0 0 200 100 10 20
|
|
75 |
restore
|
|
76 |
restore
|
|
77 |
|
|
78 |
|
|
79 |
pixmap_setMask the_pixmap mask_100.png
|
|
80 |
drawPixmap the_pixmap 0 150
|
|
81 |
setBackgroundMode Opaque
|
|
82 |
drawPixmap the_pixmap 110 150
|
|
83 |
|
|
84 |
translate 220 150
|
|
85 |
save
|
|
86 |
translate 50 50
|
|
87 |
rotate 10
|
|
88 |
translate -50 -50
|
|
89 |
setBackgroundMode Transparent
|
|
90 |
drawPixmap the_pixmap 0 0
|
|
91 |
restore
|
|
92 |
|
|
93 |
translate 110 0
|
|
94 |
save
|
|
95 |
translate 50 50
|
|
96 |
rotate 10
|
|
97 |
translate -50 -50
|
|
98 |
setBackgroundMode Opaque
|
|
99 |
drawPixmap the_pixmap 0 0
|
|
100 |
restore
|
|
101 |
|
|
102 |
resetMatrix
|
|
103 |
translate 10 650
|
|
104 |
bitmap_load dome_mono.png the_bitmap
|
|
105 |
setBackgroundMode Transparent
|
|
106 |
|
|
107 |
begin_block draw_subrected
|
|
108 |
drawPixmap the_bitmap 0 0 50 50 0 0 50 50
|
|
109 |
drawPixmap the_bitmap 50 0 50 50 50 0 50 50
|
|
110 |
drawPixmap the_bitmap 0 50 50 50 0 50 50 50
|
|
111 |
drawPixmap the_bitmap 50 50 50 50 50 50 50 50
|
|
112 |
end_block
|
|
113 |
|
|
114 |
translate 110 0
|
|
115 |
setBackgroundMode Opaque
|
|
116 |
repeat_block draw_subrected
|
|
117 |
|
|
118 |
translate 110 0
|
|
119 |
save
|
|
120 |
translate 20 -10
|
|
121 |
rotate 10
|
|
122 |
setBackgroundMode Transparent
|
|
123 |
repeat_block draw_subrected
|
|
124 |
restore
|
|
125 |
|
|
126 |
translate 110 0
|
|
127 |
save
|
|
128 |
translate 20 -10
|
|
129 |
rotate 10
|
|
130 |
setBackgroundMode Opaque
|
|
131 |
repeat_block draw_subrected
|
|
132 |
restore
|
|
133 |
|
|
134 |
# Some helpful texts
|
|
135 |
|
|
136 |
resetMatrix
|
|
137 |
setPen black
|
|
138 |
drawText 10 40 "Transparent"
|
|
139 |
drawText 120 40 "Opaque"
|
|
140 |
drawText 230 40 "Trans w/alpha"
|
|
141 |
drawText 340 40 "Opaque w/alpha"
|
|
142 |
drawText 450 40 "Trans w/xform"
|
|
143 |
drawText 560 40 "Opaque w/xform"
|
|
144 |
|
|
145 |
drawText 10 190 "Transparent tiled"
|
|
146 |
drawText 220 190 "Opaque tiled"
|
|
147 |
drawText 440 190 "Opaque w/xform"
|
|
148 |
|
|
149 |
drawText 10 340 "Transparent tiled w/offset"
|
|
150 |
drawText 220 340 "Opaque tiled w/offset"
|
|
151 |
drawText 440 340 "Opaque w/xform w/offset"
|
|
152 |
|
|
153 |
drawText 10 490 "Trans masked"
|
|
154 |
drawText 120 490 "Opaque masked"
|
|
155 |
drawText 230 490 "masked w/xform"
|
|
156 |
drawText 340 490 "masked w/xform"
|
|
157 |
|
|
158 |
drawText 10 640 "Subrected"
|
|
159 |
drawText 110 640 "Subrected opaque"
|
|
160 |
drawText 220 640 "subrect w/xform"
|
|
161 |
drawText 330 640 "subrect w/xform opaque"
|
|
162 |
|
|
163 |
|