author | Jan Vrany <jan.vrany@fit.cvut.cz> |
Thu, 10 Jul 2008 21:10:31 +0000 | |
changeset 3 | f4f599f2a1b5 |
parent 2 | c2f163833877 |
child 5 | 65635e9ef3e8 |
permissions | -rw-r--r-- |
1 | 1 |
"{ Package: 'stx:goodies/libcairo' }" |
2 |
||
3 |
"{ NameSpace: Cairo }" |
|
4 |
||
5 |
ExternalStructure subclass:#Surface |
|
6 |
instanceVariableNames:'' |
|
7 |
classVariableNames:'' |
|
8 |
poolDictionaries:'' |
|
9 |
category:'Cairo - C Types' |
|
10 |
! |
|
11 |
||
12 |
!Surface class methodsFor:'instance creation'! |
|
13 |
||
14 |
forPdfFile: aStringOrFilename width: w height: h |
|
15 |
||
16 |
^self |
|
17 |
primPdfSurfaceCreate: aStringOrFilename asFilename asString |
|
18 |
widthInPoints: w asDouble |
|
19 |
heightInPoints: h asDouble |
|
20 |
||
21 |
"Created: / 10-07-2008 / 09:35:34 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
22 |
! |
|
23 |
||
24 |
forView: view |
|
25 |
||
26 |
^view device cairoSurfaceFor: view |
|
27 |
||
28 |
"Created: / 10-07-2008 / 10:15:04 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
29 |
! |
|
30 |
||
31 |
forXlib: dpy drawable: drawable visual: visual width: width height: height |
|
32 |
||
33 |
^self primXlibSurfaceCreate: dpy drawable: drawable visual: visual width: width height: height |
|
34 |
||
35 |
"Created: / 10-07-2008 / 11:06:22 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
36 |
! ! |
|
37 |
||
38 |
!Surface class methodsFor:'accessing'! |
|
39 |
||
40 |
libraryName |
|
41 |
||
42 |
OperatingSystem isUNIXlike ifTrue:[^'libcairo.so']. |
|
43 |
||
44 |
OperatingSystem isMSWINDOWSlike ifTrue:[^'cairo.dll']. |
|
45 |
||
46 |
self error:'Library name for host OS is not known' |
|
47 |
||
3 | 48 |
"Modified: / 10-07-2008 / 23:05:54 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 49 |
! ! |
50 |
||
51 |
!Surface class methodsFor:'primitives'! |
|
52 |
||
53 |
primCopyPage: surface |
|
54 |
||
55 |
<cdecl: void "cairo_surface_copy_page" ( Cairo::Surface ) > |
|
56 |
self primitiveFailed |
|
57 |
||
3 | 58 |
"Modified: / 10-07-2008 / 23:05:54 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 59 |
! |
60 |
||
61 |
primCreateSimilar: other content: content width: width height: height |
|
62 |
||
63 |
<cdecl: Cairo::Surface "cairo_surface_create_similar" ( Cairo::Surface int32 int32 int32 ) > |
|
64 |
self primitiveFailed |
|
65 |
||
3 | 66 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 67 |
! |
68 |
||
69 |
primDestroy: surface |
|
70 |
||
71 |
<cdecl: void "cairo_surface_destroy" ( Cairo::Surface ) > |
|
72 |
self primitiveFailed |
|
73 |
||
3 | 74 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 75 |
! |
76 |
||
77 |
primFinish: surface |
|
78 |
||
79 |
<cdecl: void "cairo_surface_finish" ( Cairo::Surface ) > |
|
80 |
self primitiveFailed |
|
81 |
||
3 | 82 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 83 |
! |
84 |
||
85 |
primFlush: surface |
|
86 |
||
87 |
<cdecl: void "cairo_surface_flush" ( Cairo::Surface ) > |
|
88 |
self primitiveFailed |
|
89 |
||
3 | 90 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 91 |
! |
92 |
||
93 |
primGetContent: surface |
|
94 |
||
95 |
<cdecl: int32 "cairo_surface_get_content" ( Cairo::Surface ) > |
|
96 |
self primitiveFailed |
|
97 |
||
3 | 98 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 99 |
! |
100 |
||
101 |
primGetDeviceOffset: surface xOffset: x_offset yOffset: y_offset |
|
102 |
||
103 |
<cdecl: void "cairo_surface_get_device_offset" ( Cairo::Surface pointer pointer ) > |
|
104 |
self primitiveFailed |
|
105 |
||
3 | 106 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 107 |
! |
108 |
||
109 |
primGetFontOptions: surface options: options |
|
110 |
||
111 |
<cdecl: void "cairo_surface_get_font_options" ( Cairo::Surface Cairo::FontOptions ) > |
|
112 |
self primitiveFailed |
|
113 |
||
3 | 114 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 115 |
! |
116 |
||
117 |
primGetReferenceCount: surface |
|
118 |
||
119 |
<cdecl: uint32 "cairo_surface_get_reference_count" ( Cairo::Surface ) > |
|
120 |
self primitiveFailed |
|
121 |
||
3 | 122 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 123 |
! |
124 |
||
125 |
primGetType: surface |
|
126 |
||
127 |
<cdecl: int32 "cairo_surface_get_type" ( Cairo::Surface ) > |
|
128 |
self primitiveFailed |
|
129 |
||
3 | 130 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 131 |
! |
132 |
||
133 |
primGetUserData: surface key: key |
|
134 |
||
135 |
<cdecl: pointer "cairo_surface_get_user_data" ( Cairo::Surface Cairo::UserDataKey ) > |
|
136 |
self primitiveFailed |
|
137 |
||
3 | 138 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 139 |
! |
140 |
||
141 |
primImageSurfaceCreate: format width: width height: height |
|
142 |
||
143 |
<cdecl: Cairo::Surface "cairo_image_surface_create" ( int32 int32 int32 ) > |
|
144 |
self primitiveFailed |
|
145 |
||
3 | 146 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 147 |
! |
148 |
||
149 |
primImageSurfaceCreateForData: data format: format width: width height: height stride: stride |
|
150 |
||
151 |
<cdecl: Cairo::Surface "cairo_image_surface_create_for_data" ( pointer int32 int32 int32 int32 ) > |
|
152 |
self primitiveFailed |
|
153 |
||
3 | 154 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 155 |
! |
156 |
||
157 |
primImageSurfaceCreateFromPng: filename |
|
158 |
||
159 |
<cdecl: Cairo::Surface "cairo_image_surface_create_from_png" ( charPointer ) > |
|
160 |
self primitiveFailed |
|
161 |
||
3 | 162 |
"Modified: / 10-07-2008 / 23:05:54 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 163 |
! |
164 |
||
165 |
primImageSurfaceCreateFromPngStream: read_func closure: closure |
|
166 |
||
167 |
<cdecl: Cairo::Surface "cairo_image_surface_create_from_png_stream" ( pointer pointer ) > |
|
168 |
self primitiveFailed |
|
169 |
||
3 | 170 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 171 |
! |
172 |
||
173 |
primImageSurfaceGetData: surface |
|
174 |
||
175 |
<cdecl: pointer "cairo_image_surface_get_data" ( Cairo::Surface ) > |
|
176 |
self primitiveFailed |
|
177 |
||
3 | 178 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 179 |
! |
180 |
||
181 |
primImageSurfaceGetFormat: surface |
|
182 |
||
183 |
<cdecl: int32 "cairo_image_surface_get_format" ( Cairo::Surface ) > |
|
184 |
self primitiveFailed |
|
185 |
||
3 | 186 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 187 |
! |
188 |
||
189 |
primImageSurfaceGetHeight: surface |
|
190 |
||
191 |
<cdecl: int32 "cairo_image_surface_get_height" ( Cairo::Surface ) > |
|
192 |
self primitiveFailed |
|
193 |
||
3 | 194 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 195 |
! |
196 |
||
197 |
primImageSurfaceGetStride: surface |
|
198 |
||
199 |
<cdecl: int32 "cairo_image_surface_get_stride" ( Cairo::Surface ) > |
|
200 |
self primitiveFailed |
|
201 |
||
3 | 202 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 203 |
! |
204 |
||
205 |
primImageSurfaceGetWidth: surface |
|
206 |
||
207 |
<cdecl: int32 "cairo_image_surface_get_width" ( Cairo::Surface ) > |
|
208 |
self primitiveFailed |
|
209 |
||
3 | 210 |
"Modified: / 10-07-2008 / 23:05:54 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 211 |
! |
212 |
||
213 |
primMarkDirty: surface |
|
214 |
||
215 |
<cdecl: void "cairo_surface_mark_dirty" ( Cairo::Surface ) > |
|
216 |
self primitiveFailed |
|
217 |
||
3 | 218 |
"Modified: / 10-07-2008 / 23:05:54 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 219 |
! |
220 |
||
221 |
primMarkDirtyRectangle: surface x: x y: y width: width height: height |
|
222 |
||
223 |
<cdecl: void "cairo_surface_mark_dirty_rectangle" ( Cairo::Surface int32 int32 int32 int32 ) > |
|
224 |
self primitiveFailed |
|
225 |
||
3 | 226 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 227 |
! |
228 |
||
229 |
primPdfSurfaceCreate: filename widthInPoints: width_in_points heightInPoints: height_in_points |
|
230 |
||
231 |
<cdecl: Cairo::Surface "cairo_pdf_surface_create" ( charPointer double double ) > |
|
232 |
self primitiveFailed |
|
233 |
||
3 | 234 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 235 |
! |
236 |
||
237 |
primPdfSurfaceCreateForStream: write_func closure: closure widthInPoints: width_in_points heightInPoints: height_in_points |
|
238 |
||
239 |
<cdecl: Cairo::Surface "cairo_pdf_surface_create_for_stream" ( pointer pointer double double ) > |
|
240 |
self primitiveFailed |
|
241 |
||
3 | 242 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 243 |
! |
244 |
||
245 |
primPdfSurfaceSetSize: surface widthInPoints: width_in_points heightInPoints: height_in_points |
|
246 |
||
247 |
<cdecl: void "cairo_pdf_surface_set_size" ( Cairo::Surface double double ) > |
|
248 |
self primitiveFailed |
|
249 |
||
3 | 250 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 251 |
! |
252 |
||
253 |
primReference: surface |
|
254 |
||
255 |
<cdecl: Cairo::Surface "cairo_surface_reference" ( Cairo::Surface ) > |
|
256 |
self primitiveFailed |
|
257 |
||
3 | 258 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 259 |
! |
260 |
||
261 |
primSetDeviceOffset: surface xOffset: x_offset yOffset: y_offset |
|
262 |
||
263 |
<cdecl: void "cairo_surface_set_device_offset" ( Cairo::Surface double double ) > |
|
264 |
self primitiveFailed |
|
265 |
||
3 | 266 |
"Modified: / 10-07-2008 / 23:05:54 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 267 |
! |
268 |
||
269 |
primSetFallbackResolution: surface xPixelsPerInch: x_pixels_per_inch yPixelsPerInch: y_pixels_per_inch |
|
270 |
||
271 |
<cdecl: void "cairo_surface_set_fallback_resolution" ( Cairo::Surface double double ) > |
|
272 |
self primitiveFailed |
|
273 |
||
3 | 274 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 275 |
! |
276 |
||
277 |
primSetUserData: surface key: key userData: user_data destroy: destroy |
|
278 |
||
279 |
<cdecl: int32 "cairo_surface_set_user_data" ( Cairo::Surface Cairo::UserDataKey pointer pointer ) > |
|
280 |
self primitiveFailed |
|
281 |
||
3 | 282 |
"Modified: / 10-07-2008 / 23:05:54 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 283 |
! |
284 |
||
285 |
primShowPage: surface |
|
286 |
||
287 |
<cdecl: void "cairo_surface_show_page" ( Cairo::Surface ) > |
|
288 |
self primitiveFailed |
|
289 |
||
3 | 290 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 291 |
! |
292 |
||
293 |
primStatus: surface |
|
294 |
||
295 |
<cdecl: int32 "cairo_surface_status" ( Cairo::Surface ) > |
|
296 |
self primitiveFailed |
|
297 |
||
3 | 298 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 299 |
! |
300 |
||
301 |
primSvgSurfaceCreate: filename widthInPoints: width_in_points heightInPoints: height_in_points |
|
302 |
||
303 |
<cdecl: Cairo::Surface "cairo_svg_surface_create" ( charPointer double double ) > |
|
304 |
self primitiveFailed |
|
305 |
||
3 | 306 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 307 |
! |
308 |
||
309 |
primSvgSurfaceCreateForStream: write_func closure: closure widthInPoints: width_in_points heightInPoints: height_in_points |
|
310 |
||
311 |
<cdecl: Cairo::Surface "cairo_svg_surface_create_for_stream" ( pointer pointer double double ) > |
|
312 |
self primitiveFailed |
|
313 |
||
3 | 314 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 315 |
! |
316 |
||
317 |
primSvgSurfaceRestrictToVersion: surface version: version |
|
318 |
||
319 |
<cdecl: void "cairo_svg_surface_restrict_to_version" ( Cairo::Surface int32 ) > |
|
320 |
self primitiveFailed |
|
321 |
||
3 | 322 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 323 |
! |
324 |
||
325 |
primWriteToPng: surface filename: filename |
|
326 |
||
327 |
<cdecl: int32 "cairo_surface_write_to_png" ( Cairo::Surface charPointer ) > |
|
328 |
self primitiveFailed |
|
329 |
||
3 | 330 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 331 |
! |
332 |
||
333 |
primWriteToPngStream: surface writeFunc: write_func closure: closure |
|
334 |
||
335 |
<cdecl: int32 "cairo_surface_write_to_png_stream" ( Cairo::Surface pointer pointer ) > |
|
336 |
self primitiveFailed |
|
337 |
||
3 | 338 |
"Modified: / 10-07-2008 / 23:05:54 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 339 |
! |
340 |
||
341 |
primXlibSurfaceCreate: dpy drawable: drawable visual: visual width: width height: height |
|
342 |
||
343 |
<cdecl: Cairo::Surface "cairo_xlib_surface_create" ( pointer int32 pointer int32 int32 ) > |
|
344 |
self primitiveFailed |
|
345 |
||
3 | 346 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 347 |
! |
348 |
||
349 |
primXlibSurfaceCreateForBitmap: dpy bitmap: bitmap screen: screen width: width height: height |
|
350 |
||
351 |
<cdecl: Cairo::Surface "cairo_xlib_surface_create_for_bitmap" ( pointer int32 pointer int32 int32 ) > |
|
352 |
self primitiveFailed |
|
353 |
||
3 | 354 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 355 |
! |
356 |
||
357 |
primXlibSurfaceGetDepth: surface |
|
358 |
||
359 |
<cdecl: int32 "cairo_xlib_surface_get_depth" ( Cairo::Surface ) > |
|
360 |
self primitiveFailed |
|
361 |
||
3 | 362 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 363 |
! |
364 |
||
365 |
primXlibSurfaceGetDisplay: surface |
|
366 |
||
367 |
<cdecl: pointer "cairo_xlib_surface_get_display" ( Cairo::Surface ) > |
|
368 |
self primitiveFailed |
|
369 |
||
3 | 370 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 371 |
! |
372 |
||
373 |
primXlibSurfaceGetDrawable: surface |
|
374 |
||
375 |
<cdecl: int32 "cairo_xlib_surface_get_drawable" ( Cairo::Surface ) > |
|
376 |
self primitiveFailed |
|
377 |
||
3 | 378 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 379 |
! |
380 |
||
381 |
primXlibSurfaceGetHeight: surface |
|
382 |
||
383 |
<cdecl: int32 "cairo_xlib_surface_get_height" ( Cairo::Surface ) > |
|
384 |
self primitiveFailed |
|
385 |
||
3 | 386 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 387 |
! |
388 |
||
389 |
primXlibSurfaceGetScreen: surface |
|
390 |
||
391 |
<cdecl: pointer "cairo_xlib_surface_get_screen" ( Cairo::Surface ) > |
|
392 |
self primitiveFailed |
|
393 |
||
3 | 394 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 395 |
! |
396 |
||
397 |
primXlibSurfaceGetVisual: surface |
|
398 |
||
399 |
<cdecl: pointer "cairo_xlib_surface_get_visual" ( Cairo::Surface ) > |
|
400 |
self primitiveFailed |
|
401 |
||
3 | 402 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 403 |
! |
404 |
||
405 |
primXlibSurfaceGetWidth: surface |
|
406 |
||
407 |
<cdecl: int32 "cairo_xlib_surface_get_width" ( Cairo::Surface ) > |
|
408 |
self primitiveFailed |
|
409 |
||
3 | 410 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 411 |
! |
412 |
||
413 |
primXlibSurfaceSetDrawable: surface drawable: drawable width: width height: height |
|
414 |
||
415 |
<cdecl: void "cairo_xlib_surface_set_drawable" ( Cairo::Surface int32 int32 int32 ) > |
|
416 |
self primitiveFailed |
|
417 |
||
3 | 418 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 419 |
! |
420 |
||
421 |
primXlibSurfaceSetSize: surface width: width height: height |
|
422 |
||
423 |
<cdecl: void "cairo_xlib_surface_set_size" ( Cairo::Surface int32 int32 ) > |
|
424 |
self primitiveFailed |
|
425 |
||
3 | 426 |
"Modified: / 10-07-2008 / 23:05:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 427 |
! ! |
428 |
||
429 |
!Surface methodsFor:'accessing'! |
|
430 |
||
431 |
graphicsContext |
|
432 |
||
433 |
^GraphicsContext on: self |
|
434 |
||
435 |
"Created: / 10-07-2008 / 09:38:16 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
436 |
! |
|
437 |
||
438 |
referenceCount |
|
439 |
||
440 |
^self class primGetReferenceCount: self |
|
441 |
||
442 |
"Created: / 10-07-2008 / 10:28:49 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
443 |
! |
|
444 |
||
445 |
type |
|
446 |
||
447 |
^self class primGetType: self |
|
448 |
||
449 |
"Created: / 10-07-2008 / 10:34:36 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
2
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
450 |
! |
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
451 |
|
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
452 |
width: w height: h |
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
453 |
|
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
454 |
self class primXlibSurfaceSetSize: self width: w height: h |
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
455 |
|
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
456 |
"Created: / 10-07-2008 / 19:36:39 / Jan Vrany <vranyj1@fel.cvut.cz>" |
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
457 |
! ! |
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
458 |
|
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
459 |
!Surface methodsFor:'change & update'! |
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
460 |
|
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
461 |
update: aspect with: param from: sender |
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
462 |
|
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
463 |
(aspect = #sizeOfView and:[self type = SurfaceType SURFACE_TYPE_XLIB]) |
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
464 |
ifTrue:[^self width: sender width height: sender height]. |
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
465 |
|
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
466 |
super update: aspect with: param from: sender |
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
467 |
|
c2f163833877
Xlib surfaces are dependents of associated view
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
468 |
"Created: / 10-07-2008 / 19:33:39 / Jan Vrany <vranyj1@fel.cvut.cz>" |
1 | 469 |
! ! |
470 |
||
471 |
!Surface methodsFor:'initialization & release'! |
|
472 |
||
473 |
finalize |
|
474 |
||
475 |
Transcript showCR:'Cairo [INFO]: Finalizing surface ' ,self address hexPrintString, ' ref count: ', self referenceCount printString. |
|
476 |
self class |
|
477 |
primFlush: self; |
|
478 |
primDestroy: self |
|
479 |
||
480 |
"Created: / 10-07-2008 / 09:54:00 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
481 |
! |
|
482 |
||
483 |
flush |
|
484 |
||
485 |
^self class primFlush: self |
|
486 |
||
487 |
"Created: / 10-07-2008 / 10:32:50 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
488 |
! |
|
489 |
||
490 |
reference |
|
491 |
||
492 |
^self class primReference: self |
|
493 |
||
494 |
"Created: / 10-07-2008 / 10:28:03 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
495 |
! ! |
|
496 |