File: GtkPreview.html

package info (click to toggle)
gtk%2B2.0 2.20.1-2%2Bdeb6u2
  • links: PTS, VCS
  • area: main
  • in suites: squeeze-lts
  • size: 136,284 kB
  • ctags: 66,487
  • sloc: ansic: 590,318; sh: 10,559; makefile: 5,573; xml: 1,357; python: 866; perl: 776; asm: 457; awk: 72; cpp: 34
file content (679 lines) | stat: -rw-r--r-- 41,886 bytes parent folder | download | duplicates (2)
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
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>GtkPreview</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
<link rel="home" href="index.html" title="GTK+ Reference Manual">
<link rel="up" href="DeprecatedObjects.html" title="Deprecated">
<link rel="prev" href="GtkPixmap.html" title="GtkPixmap">
<link rel="next" href="GtkProgress.html" title="GtkProgress">
<meta name="generator" content="GTK-Doc V1.14 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
<tr valign="middle">
<td><a accesskey="p" href="GtkPixmap.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="DeprecatedObjects.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
<th width="100%" align="center">GTK+ Reference Manual</th>
<td><a accesskey="n" href="GtkProgress.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts">
<a href="#GtkPreview.synopsis" class="shortcut">Top</a>
                   | 
                  <a href="#GtkPreview.description" class="shortcut">Description</a>
                   | 
                  <a href="#GtkPreview.object-hierarchy" class="shortcut">Object Hierarchy</a>
                   | 
                  <a href="#GtkPreview.implemented-interfaces" class="shortcut">Implemented Interfaces</a>
                   | 
                  <a href="#GtkPreview.properties" class="shortcut">Properties</a>
</td></tr>
</table>
<div class="refentry" title="GtkPreview">
<a name="GtkPreview"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="GtkPreview.top_of_page"></a>GtkPreview</span></h2>
<p>GtkPreview — A widget to display RGB or grayscale data</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsynopsisdiv" title="Synopsis">
<a name="GtkPreview.synopsis"></a><h2>Synopsis</h2>
<pre class="synopsis">
#include &lt;gtk/gtk.h&gt;

                    <a class="link" href="GtkPreview.html#GtkPreview-struct" title="GtkPreview">GtkPreview</a>;
                    <a class="link" href="GtkPreview.html#GtkPreviewInfo" title="GtkPreviewInfo">GtkPreviewInfo</a>;
union               <a class="link" href="GtkPreview.html#GtkDitherInfo" title="union GtkDitherInfo">GtkDitherInfo</a>;
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-uninit" title="gtk_preview_uninit ()">gtk_preview_uninit</a>                  (<em class="parameter"><code><span class="type">void</span></code></em>);
<a class="link" href="GtkWidget.html" title="GtkWidget"><span class="returnvalue">GtkWidget</span></a>*          <a class="link" href="GtkPreview.html#gtk-preview-new" title="gtk_preview_new ()">gtk_preview_new</a>                     (<em class="parameter"><code><a class="link" href="gtk-Standard-Enumerations.html#GtkPreviewType" title="enum GtkPreviewType"><span class="type">GtkPreviewType</span></a> type</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-size" title="gtk_preview_size ()">gtk_preview_size</a>                    (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> height</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-put" title="gtk_preview_put ()">gtk_preview_put</a>                     (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/gdk/unstable/gdk-Windows.html#GdkWindow"><span class="type">GdkWindow</span></a> *window</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/gdk/unstable/gdk-Graphics-Contexts.html#GdkGC"><span class="type">GdkGC</span></a> *gc</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> srcx</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> srcy</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> destx</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> desty</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> height</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-draw-row" title="gtk_preview_draw_row ()">gtk_preview_draw_row</a>                (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guchar"><span class="type">guchar</span></a> *data</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> w</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-set-expand" title="gtk_preview_set_expand ()">gtk_preview_set_expand</a>              (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> expand</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-set-gamma" title="gtk_preview_set_gamma ()">gtk_preview_set_gamma</a>               (<em class="parameter"><code><span class="type">double</span> gamma_</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-set-color-cube" title="gtk_preview_set_color_cube ()">gtk_preview_set_color_cube</a>          (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> nred_shades</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> ngreen_shades</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> nblue_shades</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> ngray_shades</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-set-install-cmap" title="gtk_preview_set_install_cmap ()">gtk_preview_set_install_cmap</a>        (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> install_cmap</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-set-reserved" title="gtk_preview_set_reserved ()">gtk_preview_set_reserved</a>            (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> nreserved</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-set-dither" title="gtk_preview_set_dither ()">gtk_preview_set_dither</a>              (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/gdk/unstable/gdk-GdkRGB.html#GdkRgbDither"><span class="type">GdkRgbDither</span></a> dither</code></em>);
<a href="http://library.gnome.org/devel/gdk/unstable/gdk-Visuals.html#GdkVisual"><span class="returnvalue">GdkVisual</span></a>*          <a class="link" href="GtkPreview.html#gtk-preview-get-visual" title="gtk_preview_get_visual ()">gtk_preview_get_visual</a>              (<em class="parameter"><code><span class="type">void</span></code></em>);
<a href="http://library.gnome.org/devel/gdk/unstable/gdk-Colormaps-and-Colors.html#GdkColormap"><span class="returnvalue">GdkColormap</span></a>*        <a class="link" href="GtkPreview.html#gtk-preview-get-cmap" title="gtk_preview_get_cmap ()">gtk_preview_get_cmap</a>                (<em class="parameter"><code><span class="type">void</span></code></em>);
<a class="link" href="GtkPreview.html#GtkPreviewInfo" title="GtkPreviewInfo"><span class="returnvalue">GtkPreviewInfo</span></a>*     <a class="link" href="GtkPreview.html#gtk-preview-get-info" title="gtk_preview_get_info ()">gtk_preview_get_info</a>                (<em class="parameter"><code><span class="type">void</span></code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-reset" title="gtk_preview_reset ()">gtk_preview_reset</a>                   (<em class="parameter"><code><span class="type">void</span></code></em>);
</pre>
</div>
<div class="refsect1" title="Object Hierarchy">
<a name="GtkPreview.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="synopsis">
  <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject">GObject</a>
   +----<a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GInitiallyUnowned">GInitiallyUnowned</a>
         +----<a class="link" href="GtkObject.html" title="GtkObject">GtkObject</a>
               +----<a class="link" href="GtkWidget.html" title="GtkWidget">GtkWidget</a>
                     +----GtkPreview
</pre>
</div>
<div class="refsect1" title="Implemented Interfaces">
<a name="GtkPreview.implemented-interfaces"></a><h2>Implemented Interfaces</h2>
<p>
GtkPreview implements
 AtkImplementorIface and  <a class="link" href="gtk-gtkbuildable.html#GtkBuildable">GtkBuildable</a>.</p>
</div>
<div class="refsect1" title="Properties">
<a name="GtkPreview.properties"></a><h2>Properties</h2>
<pre class="synopsis">
  "<a class="link" href="GtkPreview.html#GtkPreview--expand" title='The "expand" property'>expand</a>"                   <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write
</pre>
</div>
<div class="refsect1" title="Description">
<a name="GtkPreview.description"></a><h2>Description</h2>
<p>
The <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> widget provides a simple interface
used to display images as RGB or grayscale data.
It's deprecated; just use a <a href="http://library.gnome.org/devel/gdk-pixbuf/unstable/gdk-pixbuf-gdk-pixbuf.html#GdkPixbuf"><span class="type">GdkPixbuf</span></a> displayed by a <a class="link" href="GtkImage.html" title="GtkImage"><span class="type">GtkImage</span></a>, or
perhaps a <a class="link" href="GtkDrawingArea.html" title="GtkDrawingArea"><span class="type">GtkDrawingArea</span></a>. <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> has no advantage over those
approaches.
</p>
</div>
<div class="refsect1" title="Details">
<a name="GtkPreview.details"></a><h2>Details</h2>
<div class="refsect2" title="GtkPreview">
<a name="GtkPreview-struct"></a><h3>GtkPreview</h3>
<pre class="programlisting">typedef struct _GtkPreview GtkPreview;</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">GtkPreview</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
The <a class="link" href="GtkPreview.html#GtkPreview-struct" title="GtkPreview"><span class="type">GtkPreview</span></a> struct contains private data only, and
should be accessed using the functions below.
</p>
</div>
<hr>
<div class="refsect2" title="GtkPreviewInfo">
<a name="GtkPreviewInfo"></a><h3>GtkPreviewInfo</h3>
<pre class="programlisting">typedef struct {
  guchar *lookup;

  gdouble gamma;
} GtkPreviewInfo;
</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">GtkPreviewInfo</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Contains information about global properties
of preview widgets.
The <a class="link" href="GtkPreview.html#GtkPreviewInfo" title="GtkPreviewInfo"><span class="type">GtkPreviewInfo</span></a> struct contains the following fields.
(These fields should be considered read-only. They should never be set by
an application.)
</p>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td>
<a href="http://library.gnome.org/devel/gdk/unstable/gdk-Visuals.html#GdkVisual"><span class="type">GdkVisual</span></a> *visual;</td>
<td>the visual used by all previews.</td>
</tr>
<tr>
<td>
<a href="http://library.gnome.org/devel/gdk/unstable/gdk-Colormaps-and-Colors.html#GdkColormap"><span class="type">GdkColormap</span></a> *cmap;</td>
<td>the colormap used by all previews.</td>
</tr>
<tr>
<td>gdouble gamma;</td>
<td>the gamma correction value used by all previews (See <a class="link" href="GtkPreview.html#gtk-preview-set-gamma" title="gtk_preview_set_gamma ()"><code class="function">gtk_preview_set_gamma()</code></a>).</td>
</tr>
</tbody>
</table></div>
<p>
</p>
</div>
<hr>
<div class="refsect2" title="union GtkDitherInfo">
<a name="GtkDitherInfo"></a><h3>union GtkDitherInfo</h3>
<pre class="programlisting"></pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">GtkDitherInfo</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This union not used in GTK+.
</p>
</div>
<hr>
<div class="refsect2" title="gtk_preview_uninit ()">
<a name="gtk-preview-uninit"></a><h3>gtk_preview_uninit ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_uninit                  (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_uninit</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This function is deprecated and does nothing.
</p>
</div>
<hr>
<div class="refsect2" title="gtk_preview_new ()">
<a name="gtk-preview-new"></a><h3>gtk_preview_new ()</h3>
<pre class="programlisting"><a class="link" href="GtkWidget.html" title="GtkWidget"><span class="returnvalue">GtkWidget</span></a>*          gtk_preview_new                     (<em class="parameter"><code><a class="link" href="gtk-Standard-Enumerations.html#GtkPreviewType" title="enum GtkPreviewType"><span class="type">GtkPreviewType</span></a> type</code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_new</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Create a new preview widget.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>type</code></em> :</span></p></td>
<td>the type data contained by the widget. 
(Grayscale or RGB)
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>a new <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_size ()">
<a name="gtk-preview-size"></a><h3>gtk_preview_size ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_size                    (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> height</code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_size</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Set the size that the preview widget will request
in response to a "size_request" signal. The
drawing area may actually be allocated a size
larger than this depending on how it is packed
within the enclosing containers. The effect
of this is determined by whether the preview
is set to expand or not (see <code class="function">gtk_preview_expand()</code>)
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>preview</code></em> :</span></p></td>
<td>a <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>width</code></em> :</span></p></td>
<td>the new width.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>height</code></em> :</span></p></td>
<td>the new height.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_put ()">
<a name="gtk-preview-put"></a><h3>gtk_preview_put ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_put                     (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/gdk/unstable/gdk-Windows.html#GdkWindow"><span class="type">GdkWindow</span></a> *window</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/gdk/unstable/gdk-Graphics-Contexts.html#GdkGC"><span class="type">GdkGC</span></a> *gc</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> srcx</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> srcy</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> destx</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> desty</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> height</code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_put</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Takes a portion of the contents of a preview widget
and draws it onto the given drawable, <em class="parameter"><code>window</code></em>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>preview</code></em> :</span></p></td>
<td>a <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>window</code></em> :</span></p></td>
<td>a window or pixmap.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>gc</code></em> :</span></p></td>
<td>The graphics context for the operation. Only the
     clip mask for this GC matters.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>srcx</code></em> :</span></p></td>
<td>the x coordinate of the upper left corner in the source image.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>srcy</code></em> :</span></p></td>
<td>the y coordinate of the upper left corner in the source image.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>destx</code></em> :</span></p></td>
<td>the x coordinate of the upper left corner in the destination image.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>desty</code></em> :</span></p></td>
<td>the y coordinate of the upper left corner in the destination image.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>width</code></em> :</span></p></td>
<td>the width of the rectangular portion to draw.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>height</code></em> :</span></p></td>
<td>the height of the rectangular portion to draw.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_draw_row ()">
<a name="gtk-preview-draw-row"></a><h3>gtk_preview_draw_row ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_draw_row                (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guchar"><span class="type">guchar</span></a> *data</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> w</code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_draw_row</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Sets the data for a portion of a row.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>preview</code></em> :</span></p></td>
<td>a <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>data</code></em> :</span></p></td>
<td>the new data for the portion. It should contain
       <em class="parameter"><code>w</code></em> bytes of data if the preview is of type
       GTK_TYPE_GRAYSCALE, and 3*<em class="parameter"><code>w</code></em> bytes of data
       if the preview is of type GTK_TYPE_COLOR.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>x</code></em> :</span></p></td>
<td>the starting value on the row to set.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>y</code></em> :</span></p></td>
<td>the row to change.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>w</code></em> :</span></p></td>
<td>the number of pixels in the row to change.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_set_expand ()">
<a name="gtk-preview-set-expand"></a><h3>gtk_preview_set_expand ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_set_expand              (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> expand</code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_set_expand</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Determines the way that the the preview widget behaves
when the size it is allocated is larger than the requested
size. If <em class="parameter"><code>expand</code></em> is <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a>, then the preview's window
and buffer will be no larger than the size set with
<a class="link" href="GtkPreview.html#gtk-preview-size" title="gtk_preview_size ()"><code class="function">gtk_preview_size()</code></a>, and the data set will be centered
in the allocation if it is larger. If <em class="parameter"><code>expand</code></em> is <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a>
then the window and buffer will expand with the allocation;
the application is responsible for catching
the "size_allocate" signal and providing the data
appropriate for this size.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>preview</code></em> :</span></p></td>
<td>a <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>expand</code></em> :</span></p></td>
<td>whether the preview's window should expand or not.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_set_gamma ()">
<a name="gtk-preview-set-gamma"></a><h3>gtk_preview_set_gamma ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_set_gamma               (<em class="parameter"><code><span class="type">double</span> gamma_</code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_set_gamma</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Set the gamma-correction value for all preview widgets.
(This function will eventually be replaced with a
function that sets a per-preview-widget gamma value).
The resulting intensity is given by:
<code class="literal">destination_value * pow (source_value/255, 1/gamma)</code>.
The gamma value is applied when the data is
set with <a class="link" href="GtkPreview.html#gtk-preview-draw-row" title="gtk_preview_draw_row ()"><code class="function">gtk_preview_draw_row()</code></a> so changing this
value will not affect existing data in preview
widgets.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>gamma_</code></em> :</span></p></td>
<td>the new gamma value.
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_set_color_cube ()">
<a name="gtk-preview-set-color-cube"></a><h3>gtk_preview_set_color_cube ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_set_color_cube          (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> nred_shades</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> ngreen_shades</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> nblue_shades</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> ngray_shades</code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_set_color_cube</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This function is deprecated and does nothing. GdkRGB
automatically picks an optimium color cube for the
display.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>nred_shades</code></em> :</span></p></td>
<td>ignored
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>ngreen_shades</code></em> :</span></p></td>
<td>ignored
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>nblue_shades</code></em> :</span></p></td>
<td>ignored
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>ngray_shades</code></em> :</span></p></td>
<td>ignored
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_set_install_cmap ()">
<a name="gtk-preview-set-install-cmap"></a><h3>gtk_preview_set_install_cmap ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_set_install_cmap        (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> install_cmap</code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_set_install_cmap</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This function is deprecated
and does nothing. GdkRGB will automatically pick
a private colormap if it cannot allocate sufficient
colors.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>install_cmap</code></em> :</span></p></td>
<td>ignored.
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_set_reserved ()">
<a name="gtk-preview-set-reserved"></a><h3>gtk_preview_set_reserved ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_set_reserved            (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> nreserved</code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_set_reserved</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This function is deprecated and does nothing.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>nreserved</code></em> :</span></p></td>
<td>ignored.
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_set_dither ()">
<a name="gtk-preview-set-dither"></a><h3>gtk_preview_set_dither ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_set_dither              (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/gdk/unstable/gdk-GdkRGB.html#GdkRgbDither"><span class="type">GdkRgbDither</span></a> dither</code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_set_dither</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Set the dithering mode for the display.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>preview</code></em> :</span></p></td>
<td>a <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>dither</code></em> :</span></p></td>
<td>the dithering mode.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_get_visual ()">
<a name="gtk-preview-get-visual"></a><h3>gtk_preview_get_visual ()</h3>
<pre class="programlisting"><a href="http://library.gnome.org/devel/gdk/unstable/gdk-Visuals.html#GdkVisual"><span class="returnvalue">GdkVisual</span></a>*          gtk_preview_get_visual              (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_get_visual</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Returns the visual used by preview widgets. This
function is deprecated, and you should use
<a href="http://library.gnome.org/devel/gdk/unstable/gdk-GdkRGB.html#gdk-rgb-get-visual"><code class="function">gdk_rgb_get_visual()</code></a> instead.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>the visual for previews.
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_get_cmap ()">
<a name="gtk-preview-get-cmap"></a><h3>gtk_preview_get_cmap ()</h3>
<pre class="programlisting"><a href="http://library.gnome.org/devel/gdk/unstable/gdk-Colormaps-and-Colors.html#GdkColormap"><span class="returnvalue">GdkColormap</span></a>*        gtk_preview_get_cmap                (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_get_cmap</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Returns the colormap used by preview widgets. This
function is deprecated, and you should use
<a href="http://library.gnome.org/devel/gdk/unstable/gdk-GdkRGB.html#gdk-rgb-get-cmap"><code class="function">gdk_rgb_get_cmap()</code></a> instead.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>the colormap for previews.
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_get_info ()">
<a name="gtk-preview-get-info"></a><h3>gtk_preview_get_info ()</h3>
<pre class="programlisting"><a class="link" href="GtkPreview.html#GtkPreviewInfo" title="GtkPreviewInfo"><span class="returnvalue">GtkPreviewInfo</span></a>*     gtk_preview_get_info                (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_get_info</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Return a <a class="link" href="GtkPreview.html#GtkPreviewInfo" title="GtkPreviewInfo"><span class="type">GtkPreviewInfo</span></a> structure containing
global information about preview widgets.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>a <a class="link" href="GtkPreview.html#GtkPreviewInfo" title="GtkPreviewInfo"><span class="type">GtkPreviewInfo</span></a> structure. The return
 value belongs to GTK+ and must not be modified
 or freed.
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="gtk_preview_reset ()">
<a name="gtk-preview-reset"></a><h3>gtk_preview_reset ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_reset                   (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_reset</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This function is deprecated and does nothing. It was
once used for changing the colormap and visual on the fly.
</p>
</div>
</div>
<div class="refsect1" title="Property Details">
<a name="GtkPreview.property-details"></a><h2>Property Details</h2>
<div class="refsect2" title='The "expand" property'>
<a name="GtkPreview--expand"></a><h3>The <code class="literal">"expand"</code> property</h3>
<pre class="programlisting">  "expand"                   <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write</pre>
<p>Whether the preview widget should take up the entire space it is allocated.</p>
<p>Default value: FALSE</p>
</div>
</div>
<div class="refsect1" title="See Also">
<a name="GtkPreview.see-also"></a><h2>See Also</h2>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><span class="type">GdkRGB</span></span></p></td>
<td><p>the backend used by <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>.</p></td>
</tr></tbody>
</table></div>
<p>
</p>
</div>
</div>
<div class="footer">
<hr>
          Generated by GTK-Doc V1.14</div>
</body>
</html>