summaryrefslogtreecommitdiff
path: root/PluginDevelopment.pdf
blob: 9c6475bb7373b743b9c1665b4faa4c825139c24c (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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
%PDF-1.3
% ReportLab Generated PDF document http://www.reportlab.com
% 'BasicFonts': class PDFDictionary 
1 0 obj
% The standard fonts dictionary
<< /F1 2 0 R
 /F2 3 0 R
 /F3 4 0 R
 /F4 11 0 R >>
endobj
% 'F1': class PDFType1Font 
2 0 obj
% Font Helvetica
<< /BaseFont /Helvetica
 /Encoding /WinAnsiEncoding
 /Name /F1
 /Subtype /Type1
 /Type /Font >>
endobj
% 'F2': class PDFType1Font 
3 0 obj
% Font Helvetica-Bold
<< /BaseFont /Helvetica-Bold
 /Encoding /WinAnsiEncoding
 /Name /F2
 /Subtype /Type1
 /Type /Font >>
endobj
% 'F3': class PDFType1Font 
4 0 obj
% Font Helvetica-BoldOblique
<< /BaseFont /Helvetica-BoldOblique
 /Encoding /WinAnsiEncoding
 /Name /F3
 /Subtype /Type1
 /Type /Font >>
endobj
% 'Annot.NUMBER1': class LinkAnnotation 
5 0 obj
<< /Border [ 0
 0
 0 ]
 /Contents ()
 /Dest [ 12 0 R
 /Fit ]
 /Rect [ 74.69291
 703.7669
 532.5827
 715.7669 ]
 /Subtype /Link
 /Type /Annot >>
endobj
% 'Annot.NUMBER2': class LinkAnnotation 
6 0 obj
<< /Border [ 0
 0
 0 ]
 /Contents ()
 /Dest [ 12 0 R
 /Fit ]
 /Rect [ 74.69291
 685.7669
 532.5827
 697.7669 ]
 /Subtype /Link
 /Type /Annot >>
endobj
% 'Annot.NUMBER3': class LinkAnnotation 
7 0 obj
<< /Border [ 0
 0
 0 ]
 /Contents ()
 /Dest [ 13 0 R
 /Fit ]
 /Rect [ 74.69291
 667.7669
 532.5827
 679.7669 ]
 /Subtype /Link
 /Type /Annot >>
endobj
% 'Annot.NUMBER4': class LinkAnnotation 
8 0 obj
<< /Border [ 0
 0
 0 ]
 /Contents ()
 /Dest [ 13 0 R
 /Fit ]
 /Rect [ 74.69291
 649.7669
 532.5827
 661.7669 ]
 /Subtype /Link
 /Type /Annot >>
endobj
% 'Annot.NUMBER5': class LinkAnnotation 
9 0 obj
<< /Border [ 0
 0
 0 ]
 /Contents ()
 /Dest [ 13 0 R
 /Fit ]
 /Rect [ 74.69291
 631.7669
 532.5827
 643.7669 ]
 /Subtype /Link
 /Type /Annot >>
endobj
% 'Annot.NUMBER6': class LinkAnnotation 
10 0 obj
<< /Border [ 0
 0
 0 ]
 /Contents ()
 /Dest [ 13 0 R
 /Fit ]
 /Rect [ 74.69291
 613.7669
 532.5827
 625.7669 ]
 /Subtype /Link
 /Type /Annot >>
endobj
% 'F4': class PDFType1Font 
11 0 obj
% Font Helvetica-Oblique
<< /BaseFont /Helvetica-Oblique
 /Encoding /WinAnsiEncoding
 /Name /F4
 /Subtype /Type1
 /Type /Font >>
endobj
% 'Page1': class PDFPage 
12 0 obj
% Page dictionary
<< /Annots [ 5 0 R
 6 0 R
 7 0 R
 8 0 R
 9 0 R
 10 0 R ]
 /Contents 25 0 R
 /MediaBox [ 0
 0
 595.2756
 841.8898 ]
 /Parent 24 0 R
 /Resources << /Font 1 0 R
 /ProcSet [ /PDF
 /Text
 /ImageB
 /ImageC
 /ImageI ] >>
 /Rotate 0
 /Trans <<  >>
 /Type /Page >>
endobj
% 'Page2': class PDFPage 
13 0 obj
% Page dictionary
<< /Contents 26 0 R
 /MediaBox [ 0
 0
 595.2756
 841.8898 ]
 /Parent 24 0 R
 /Resources << /Font 1 0 R
 /ProcSet [ /PDF
 /Text
 /ImageB
 /ImageC
 /ImageI ] >>
 /Rotate 0
 /Trans <<  >>
 /Type /Page >>
endobj
% 'Page3': class PDFPage 
14 0 obj
% Page dictionary
<< /Contents 27 0 R
 /MediaBox [ 0
 0
 595.2756
 841.8898 ]
 /Parent 24 0 R
 /Resources << /Font 1 0 R
 /ProcSet [ /PDF
 /Text
 /ImageB
 /ImageC
 /ImageI ] >>
 /Rotate 0
 /Trans <<  >>
 /Type /Page >>
endobj
% 'R15': class PDFCatalog 
15 0 obj
% Document Root
<< /Outlines 17 0 R
 /PageMode /UseNone
 /Pages 24 0 R
 /Type /Catalog >>
endobj
% 'R16': class PDFInfo 
16 0 obj
<< /Author ()
 /CreationDate (D:20100412154915-01'00')
 /Keywords ()
 /Producer (ReportLab http://www.reportlab.com)
 /Subject (\(unspecified\))
 /Title (Plugin development for Compiz Fusion) >>
endobj
% 'R17': class PDFOutlines 
17 0 obj
<< /Count 6
 /First 18 0 R
 /Last 23 0 R
 /Type /Outlines >>
endobj
% 'Outline.0': class OutlineEntryObject 
18 0 obj
<< /Dest [ 12 0 R
 /Fit ]
 /Next 19 0 R
 /Parent 17 0 R
 /Title (0. About this document) >>
endobj
% 'Outline.1': class OutlineEntryObject 
19 0 obj
<< /Dest [ 12 0 R
 /Fit ]
 /Next 20 0 R
 /Parent 17 0 R
 /Prev 18 0 R
 /Title (1. Plugin initialization and finalization) >>
endobj
% 'Outline.2': class OutlineEntryObject 
20 0 obj
<< /Dest [ 13 0 R
 /Fit ]
 /Next 21 0 R
 /Parent 17 0 R
 /Prev 19 0 R
 /Title (2. Dealing with options) >>
endobj
% 'Outline.3': class OutlineEntryObject 
21 0 obj
<< /Dest [ 13 0 R
 /Fit ]
 /Next 22 0 R
 /Parent 17 0 R
 /Prev 20 0 R
 /Title (3. Hooking into core) >>
endobj
% 'Outline.4': class OutlineEntryObject 
22 0 obj
<< /Dest [ 13 0 R
 /Fit ]
 /Next 23 0 R
 /Parent 17 0 R
 /Prev 21 0 R
 /Title (4. Debugging) >>
endobj
% 'Outline.5': class OutlineEntryObject 
23 0 obj
<< /Dest [ 13 0 R
 /Fit ]
 /Parent 17 0 R
 /Prev 22 0 R
 /Title (5. Pitfalls) >>
endobj
% 'R24': class PDFPages 
24 0 obj
% page tree
<< /Count 3
 /Kids [ 12 0 R
 13 0 R
 14 0 R ]
 /Type /Pages >>
endobj
% 'R25': class PDFStream 
25 0 obj
% page stream
<< /Length 6388 >>
stream
1 0 0 1 0 0 cm BT /F1 12 Tf 14.4 TL ET
q
1 0 0 1 62.69291 779.1969 cm
Q
q
1 0 0 1 62.69291 755.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 9.64 Tm /F2 20 Tf 24 TL 49.36488 0 Td (Plugin development for Compiz Fusion) Tj T* -49.36488 0 Td ET
Q
Q
q
1 0 0 1 62.69291 745.1969 cm
Q
q
1 0 0 1 62.69291 718.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 6.025 Tm /F3 12.5 Tf 15 TL (Table of Contents) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 700.1969 cm
q
0 0 .501961 rg
0 0 .501961 RG
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL (0. About this document) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 682.1969 cm
q
0 0 .501961 rg
0 0 .501961 RG
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL (1. Plugin initialization and finalization) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 664.1969 cm
q
0 0 .501961 rg
0 0 .501961 RG
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL (2. Dealing with options) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 646.1969 cm
q
0 0 .501961 rg
0 0 .501961 RG
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL (3. Hooking into core) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 628.1969 cm
q
0 0 .501961 rg
0 0 .501961 RG
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL (4. Debugging) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 610.1969 cm
q
0 0 .501961 rg
0 0 .501961 RG
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL (5. Pitfalls) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 610.1969 cm
Q
q
1 0 0 1 62.69291 610.1969 cm
Q
q
1 0 0 1 62.69291 577.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 8.435 Tm /F2 17.5 Tf 21 TL (0. About this document) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 547.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 16.82 Tm /F1 10 Tf 12 TL 1.184987 Tw (This is meant to be a brief introduction to development. It applies to both new plugins, and working on) Tj T* 0 Tw (existing plugins.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 517.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 16.82 Tm /F1 10 Tf 12 TL .340574 Tw (When talking about Compiz development, we talk about plugins and core. Core is the part of Compiz that) Tj T* 0 Tw (are running and not plugins. In other words, it's Compiz.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 517.1969 cm
Q
q
1 0 0 1 62.69291 517.1969 cm
Q
q
1 0 0 1 62.69291 484.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 8.435 Tm /F2 17.5 Tf 21 TL (1. Plugin initialization and finalization) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 454.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 16.82 Tm /F1 10 Tf 12 TL .332619 Tw (Plugin initialization starts with a dlOpen, and the only data that core reads is the vTable, and as such, the) Tj T* 0 Tw (vTable is essential.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 412.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 28.82 Tm /F1 10 Tf 12 TL 1.246098 Tw (The vTable is almost almost found at the bottom of all plugins, and the content of the vTable changes) Tj T* 0 Tw 1.201984 Tw (from time to time. One thing remains the same, however: The vTable contains the unique plugin-name) Tj T* 0 Tw (and function pointers to various initialization and finalization functions.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 370.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 28.82 Tm /F1 10 Tf 12 TL .92881 Tw (Generally you never modify the vTable in a plugin except to track core changes. When dealing with the) Tj T* 0 Tw 1.340542 Tw (vTable, bcop also comes into play. BCop is a code generator used in most of Compiz Fusion, but not) Tj T* 0 Tw (Compiz. It allows generation of much of the option handling code, based on metadata. More on bcop later.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 280.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 76.82 Tm /F1 10 Tf 12 TL .259431 Tw (The vTable currently only contains getMetadata, which you should let bcop handle, so just leave it as 0 \(it) Tj T* 0 Tw 2.164651 Tw (simply returns a pointer to the metadata structure, which bcop generates for us\). The initPlugin and) Tj T* 0 Tw .256235 Tw (finiPlugin functions are, respectively, the first and last functions to be executed by the plugin. They should) Tj T* 0 Tw 1.77881 Tw (allocate your displayPrivateIndex, which is the only variable that has to be stored in the plugin in file) Tj T* 0 Tw .445488 Tw (scope. It is an index we will use later, to store private data in CompDisplay. You may wonder why it's not) Tj T* 0 Tw 1.152126 Tw (allocated during display initialization; That's because there may be multiple Displays, and we only want) Tj T* 0 Tw (one index. The same applies to all indexes, as you will see shortly.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 238.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 28.82 Tm /F1 10 Tf 12 TL .158314 Tw (Next in the vTable we have initObject and finiObject. Previously, we had {init|fini}{Screen|Display|Window}) Tj T* 0 Tw 1.547984 Tw (instead. Now we have {init|fini}Object which returns a list of these functions. This was implemented in) Tj T* 0 Tw (anticipation of a more advanced object framework.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 172.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 52.82 Tm /F1 10 Tf 12 TL .569986 Tw (initDisplay is called first, and you want to allocate your PluginDisplay structure here if you need one, and) Tj T* 0 Tw .152485 Tw (wrap anything that takes place in display-context. This generally means anything that has to do with input.) Tj T* 0 Tw 1.804269 Tw (Also, allocate a screenPrivateIndex, and store it. Since Compiz, in theory, can have multiple displays) Tj T* 0 Tw 5.571235 Tw (\(though the author has no idea why or how\), it is considered good practice to store the) Tj T* 0 Tw (screenPracticeIndex in your PluginDisplay variable.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 106.1969 cm
q
BT 1 0 0 1 0 52.82 Tm 1.288221 Tw 12 TL /F1 10 Tf 0 0 0 rg (initScreen is called for ) Tj /F4 10 Tf (each screen ) Tj /F1 10 Tf (after this. It should do set up the PluginScreen structure and wrap) Tj T* 0 Tw .533735 Tw (anything related to output. You should probably read up on Multihead to understand how Compiz may or) Tj T* 0 Tw .432485 Tw (may not have multiple CompScreen structures on mutlihead setups. The rule of thumb is that you always) Tj T* 0 Tw 1.05561 Tw (do output in CompScreen context, and that if you have to work on CompScreen in display-context, you) Tj T* 0 Tw (have to iterate over all the possible screens.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 76.19685 cm
q
0 0 0 rg
BT 1 0 0 1 0 16.82 Tm /F1 10 Tf 12 TL 1.84528 Tw (Lastly, we have initWindow. This is run both when you load your plugin and when new windows are) Tj T* 0 Tw (created. You setup up window-private data here, similar to initScreen.) Tj T* ET
Q
Q
 
endstream

endobj
% 'R26': class PDFStream 
26 0 obj
% page stream
<< /Length 6752 >>
stream
1 0 0 1 0 0 cm BT /F1 12 Tf 14.4 TL ET
q
1 0 0 1 62.69291 731.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 40.82 Tm /F1 10 Tf 12 TL 3.278651 Tw (On unload, finiWindow will be called for all windows, followed by finiScreen for all screens, then) Tj T* 0 Tw 1.259318 Tw (finiDisplay, then finiPlugin. On unload, you only need to worry about disabeling all timeouts \(that's why) Tj T* 0 Tw 1.876235 Tw (you store their handlers, right?\), UNWRAP anything you WRAP'ed in init*, then free \(\) data and free) Tj T* 0 Tw (indexes you allocated in the same init*.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 731.1969 cm
Q
q
1 0 0 1 62.69291 731.1969 cm
Q
q
1 0 0 1 62.69291 698.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 8.435 Tm /F2 17.5 Tf 21 TL (2. Dealing with options) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 644.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 40.82 Tm /F1 10 Tf 12 TL 1.267209 Tw (There are two ways to deal with options. It's the Compiz way, and the Compiz Fusion way. In Compiz) Tj T* 0 Tw .593318 Tw (Fusion, we use bcop \(Beryl/Compiz Option generator, or something along those lines\). It's from the days) Tj T* 0 Tw .905251 Tw (of Beryl, and takes care of all the boring parts of option handling. To understand what it does, we'll first) Tj T* 0 Tw (look at how Compiz handles options.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 590.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 40.82 Tm /F1 10 Tf 12 TL 2.11936 Tw (Options are stored in metadata files, typically xml. I won't go into details on how CompizConfig and) Tj T* 0 Tw 1.415251 Tw (Compiz handles it, but the essential part is that the data needs to be available from BOTH C and the) Tj T* 0 Tw .813735 Tw (XML-data. In Compiz, that means you have the .xml files which contains descriptions used in gconf and) Tj T* 0 Tw (ccsm. In the C code, you have a metadata structure which essentially duplicates this data.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 536.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 40.82 Tm /F1 10 Tf 12 TL 3.807765 Tw (You also have to have functions set up to handle when an option change, to store it in your) Tj T* 0 Tw .113516 Tw (PluginFoo-variable. As you can imagine, this is mostly identical in all plugins. What bcop does is take your) Tj T* 0 Tw .324985 Tw (xml data and generate the metadata structure from it, then it generates get/set functions and modifies the) Tj T* 0 Tw (relevant bindings to core.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 506.1969 cm
q
BT 1 0 0 1 0 16.82 Tm .211807 Tw 12 TL /F1 10 Tf 0 0 0 rg (This means a few things: 1. No get/set code or option code at all in your plugin. 2. No direct access to the) Tj T* 0 Tw (option-values, or ") Tj (default) Tj (" functions that are called when an option change.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 452.1969 cm
q
BT 1 0 0 1 0 40.82 Tm .296651 Tw 12 TL /F1 10 Tf 0 0 0 rg (bcop solves the lack of direct access by generating functions that take the form of ") Tj (pluginGetOptionName) Tj T* 0 Tw .359986 Tw (\(foo\)) Tj (") Tj (, where foo is the core structure of the relevant scope. Convention in metadata is to use underscore) Tj T* 0 Tw 1.795318 Tw (for option names, while Compiz uses camelCase, so bcop translates this for you. So some_option in) Tj T* 0 Tw (Display context can be accessed by calling pluginGetSomeOption \(d\), assuming d is a CompDisplay.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 422.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 16.82 Tm /F1 10 Tf 12 TL 3.793318 Tw (To watch for an option change, you can use pluginSetOptionNotify \(foo, bar\), where foo is the) Tj T* 0 Tw (context-variable \(CompDisplay, for instance\) and bar is a function that will be executed.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 422.1969 cm
Q
q
1 0 0 1 62.69291 422.1969 cm
Q
q
1 0 0 1 62.69291 389.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 8.435 Tm /F2 17.5 Tf 21 TL (3. Hooking into core) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 251.1969 cm
q
BT 1 0 0 1 0 124.82 Tm .148988 Tw 12 TL /F1 10 Tf 0 0 0 rg (So now you can start your plugin and even read, set and watch for option changes. To make it actually do) Tj T* 0 Tw .188735 Tw (something meaningful, you need to hook into core. For that, you need two macros, WRAP and UNWRAP.) Tj T* 0 Tw 3.438443 Tw (These are essentially stack push/pop operators. The core structures has a number of wrappable) Tj T* 0 Tw 1.517045 Tw (functions, for instance to paint an output device. To modify how an output device \(ie: your monitor\) is) Tj T* 0 Tw .152209 Tw (drawn you tell core that whenever it's about to update the output, run OUR function. This means you have) Tj T* 0 Tw 1.419986 Tw (to make sure you actually run the core-version afterwards. In reality, plugins stack this on top of each) Tj T* 0 Tw 1.931235 Tw (other, so when you wrap a function, you're most likely saying ") Tj (execute my function before this other) Tj T* 0 Tw 1.149984 Tw (plugins function) Tj (") Tj (. This is why load order is essential when creating effects that persist through different) Tj T* 0 Tw 1.524987 Tw (plugins, like the fade plugin which looks at the intended opacity for a window paint and modifies it so) Tj T* 0 Tw .041654 Tw (instead of an instant change, we get a smooth gradual change, regardless of wether it was an other plugin) Tj T* 0 Tw (that modified the opacity, or core.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 221.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 16.82 Tm /F1 10 Tf 12 TL .815542 Tw (Unfortunately, there are far too many wrappables to explain them all here. You will have to look at what) Tj T* 0 Tw (other plugins do, or ask around. Hopefully, more documentation will arrive.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 221.1969 cm
Q
q
1 0 0 1 62.69291 221.1969 cm
Q
q
1 0 0 1 62.69291 188.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 8.435 Tm /F2 17.5 Tf 21 TL (4. Debugging) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 146.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 28.82 Tm /F1 10 Tf 12 TL .600542 Tw (Debugging a compiz plugin is hard. You will be restarting compiz a lot. Using gdb on compiz means that) Tj T* 0 Tw .742619 Tw (you STOP your window manager, and input and output along with it. If you really want to use GDB, you) Tj T* 0 Tw (need to do it remotely.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 104.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 28.82 Tm /F1 10 Tf 12 TL .322209 Tw (Luckily, we have a crashhandler plugin that runs gdb for you if compiz crashes. If you are running compiz) Tj T* 0 Tw .495777 Tw (in a terminal \(like you should\), this should give you what you need to debug crashes. Other than that, it's) Tj T* 0 Tw (mostly printf.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 86.19685 cm
q
0 0 0 rg
BT 1 0 0 1 0 4.82 Tm /F1 10 Tf 12 TL (Some might mention valgrind, but if you need valgrind, you're in deep water.) Tj T* ET
Q
Q
q
1 0 0 1 62.69291 86.19685 cm
Q
q
1 0 0 1 62.69291 86.19685 cm
Q
 
endstream

endobj
% 'R27': class PDFStream 
27 0 obj
% page stream
<< /Length 1039 >>
stream
1 0 0 1 0 0 cm BT /F1 12 Tf 14.4 TL ET
q
1 0 0 1 62.69291 758.1969 cm
q
0 0 0 rg
BT 1 0 0 1 0 8.435 Tm /F2 17.5 Tf 21 TL (5. Pitfalls) Tj T* ET
Q
Q
q
1 0 0 1 82.69291 740.1969 cm
q
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL 0 0 0 rg (\177) Tj ET
0 0 0 rg
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL 9.5 0 Td (Mixing up WRAP/UNWRAP order, specially on unload.) Tj T* -9.5 0 Td ET
Q
Q
q
1 0 0 1 82.69291 722.1969 cm
q
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL 0 0 0 rg (\177) Tj ET
0 0 0 rg
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL 9.5 0 Td (Mixing up CompScreen and CompDisplay context. Read Documentation/Multihead.) Tj T* -9.5 0 Td ET
Q
Q
q
1 0 0 1 82.69291 704.1969 cm
q
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL 0 0 0 rg (\177) Tj ET
0 0 0 rg
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL 9.5 0 Td (Not unloading properly.) Tj T* -9.5 0 Td ET
Q
Q
q
1 0 0 1 82.69291 686.1969 cm
q
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL 0 0 0 rg (\177) Tj ET
0 0 0 rg
BT 1 0 0 1 12 4.82 Tm /F1 10 Tf 12 TL 9.5 0 Td (?) Tj T* -9.5 0 Td ET
Q
Q
 
endstream

endobj
xref
0 28
0000000000 65535 f
0000000113 00000 n
0000000246 00000 n
0000000411 00000 n
0000000586 00000 n
0000000788 00000 n
0000001003 00000 n
0000001218 00000 n
0000001433 00000 n
0000001648 00000 n
0000001863 00000 n
0000002066 00000 n
0000002246 00000 n
0000002587 00000 n
0000002867 00000 n
0000003148 00000 n
0000003286 00000 n
0000003534 00000 n
0000003659 00000 n
0000003816 00000 n
0000004007 00000 n
0000004180 00000 n
0000004350 00000 n
0000004512 00000 n
0000004642 00000 n
0000004768 00000 n
0000011257 00000 n
0000018110 00000 n
trailer
<< /ID 
 % ReportLab generated PDF document -- digest (http://www.reportlab.com) 
 [(,\236\022\326\3244lo{<]\034F\322\275\366) (,\236\022\326\3244lo{<]\034F\322\275\366)] 

 /Info 16 0 R
 /Root 15 0 R
 /Size 28 >>
startxref
19223
%%EOF