1
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
4
<meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
5
<title>GimpZoomPreview</title>
6
<meta name="generator" content="DocBook XSL Stylesheets V1.72.0">
7
<link rel="start" href="index.html" title="GIMP Library Reference Manual">
8
<link rel="up" href="libgimpui.html" title="Part II. GIMP User Interface Library">
9
<link rel="prev" href="GimpAspectPreview.html" title="GimpAspectPreview">
10
<link rel="next" href="libgimp-GimpItemComboBox.html" title="GimpItemComboBox">
11
<meta name="generator" content="GTK-Doc V1.8 (XML mode)">
12
<link rel="stylesheet" href="style.css" type="text/css">
13
<link rel="part" href="libgimp.html" title="Part I. GIMP Library">
14
<link rel="chapter" href="libgimp-general.html" title="Functions not Related to Specific Images">
15
<link rel="chapter" href="libgimp-image.html" title="Manupulating Images and their Properties">
16
<link rel="chapter" href="libgimp-data.html" title="Data Objects">
17
<link rel="chapter" href="libgimp-selectors.html" title="Controlling the Core's Selection Dialogs">
18
<link rel="part" href="libgimpui.html" title="Part II. GIMP User Interface Library">
19
<link rel="chapter" href="libgimpui-hierarchy.html" title="Object Hierarchy">
20
<link rel="index" href="libgimp-index.html" title="Index">
21
<link rel="index" href="libgimp-index-new-in-2-2.html" title="Index of new symbols in GIMP 2.2">
22
<link rel="index" href="libgimp-index-new-in-2-4.html" title="Index of new symbols in GIMP 2.4">
23
<link rel="index" href="libgimp-index-deprecated.html" title="Index of deprecated symbols">
25
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
26
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
28
<td><a accesskey="p" href="GimpAspectPreview.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
29
<td><a accesskey="u" href="libgimpui.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
30
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
31
<th width="100%" align="center">GIMP Library Reference Manual</th>
32
<td><a accesskey="n" href="libgimp-GimpItemComboBox.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
34
<tr><td colspan="5" class="shortcuts"><nobr><a href="#id2559171" class="shortcut">Top</a>
36
<a href="#id2710636" class="shortcut">Description</a>
38
<a href="#id2712943" class="shortcut">Object Hierarchy</a>
40
<a href="#id2710573" class="shortcut">Implemented Interfaces</a>
42
<a href="#id2710594" class="shortcut">Properties</a></nobr></td></tr>
44
<div class="refentry" lang="en">
45
<a name="GimpZoomPreview"></a><div class="titlepage"></div>
46
<div class="refnamediv"><table width="100%"><tr>
49
<a name="id2559171"></a><span class="refentrytitle">GimpZoomPreview</span>
51
<p>GimpZoomPreview</p>
53
<td valign="top" align="right"></td>
55
<div class="refsynopsisdiv">
57
<pre class="synopsis">
61
<a href="GimpZoomPreview.html#GimpZoomPreview-struct">GimpZoomPreview</a>;
62
GtkWidget* <a href="GimpZoomPreview.html#gimp-zoom-preview-new">gimp_zoom_preview_new</a> (<a href="libgimp-gimpdrawable.html#GimpDrawable">GimpDrawable</a> *drawable);
63
GtkWidget* <a href="GimpZoomPreview.html#gimp-zoom-preview-new-with-model">gimp_zoom_preview_new_with_model</a> (<a href="libgimp-gimpdrawable.html#GimpDrawable">GimpDrawable</a> *drawable,
64
GimpZoomModel *model);
65
guchar* <a href="GimpZoomPreview.html#gimp-zoom-preview-get-source">gimp_zoom_preview_get_source</a> (<a href="GimpZoomPreview.html" title="GimpZoomPreview">GimpZoomPreview</a> *preview,
69
<a href="libgimp-gimpdrawable.html#GimpDrawable">GimpDrawable</a>* <a href="GimpZoomPreview.html#gimp-zoom-preview-get-drawable">gimp_zoom_preview_get_drawable</a> (<a href="GimpZoomPreview.html" title="GimpZoomPreview">GimpZoomPreview</a> *preview);
70
gdouble <a href="GimpZoomPreview.html#gimp-zoom-preview-get-factor">gimp_zoom_preview_get_factor</a> (<a href="GimpZoomPreview.html" title="GimpZoomPreview">GimpZoomPreview</a> *preview);
71
GimpZoomModel* <a href="GimpZoomPreview.html#gimp-zoom-preview-get-model">gimp_zoom_preview_get_model</a> (<a href="GimpZoomPreview.html" title="GimpZoomPreview">GimpZoomPreview</a> *preview);
75
<div class="refsect1" lang="en">
76
<a name="id2712943"></a><h2>Object Hierarchy</h2>
77
<pre class="synopsis">
80
+----GInitiallyUnowned
87
href="../libgimpwidgets/GimpPreview.html"
90
href="../libgimpwidgets/GimpScrolledPreview.html"
91
>GimpScrolledPreview</a>
95
<div class="refsect1" lang="en">
96
<a name="id2710573"></a><h2>Implemented Interfaces</h2>
98
GimpZoomPreview implements
99
AtkImplementorIface.</p>
101
<div class="refsect1" lang="en">
102
<a name="id2710594"></a><h2>Properties</h2>
103
<pre class="synopsis">
105
"<a href="GimpZoomPreview.html#GimpZoomPreview--drawable">drawable</a>" gpointer : Read / Write / Construct Only
106
"<a href="GimpZoomPreview.html#GimpZoomPreview--model">model</a>" GimpZoomModel : Read / Write / Construct Only
109
<div class="refsect1" lang="en">
110
<a name="id2710636"></a><h2>Description</h2>
115
<div class="refsect1" lang="en">
116
<a name="id2710652"></a><h2>Details</h2>
117
<div class="refsect2" lang="en">
118
<a name="id2710663"></a><h3>
119
<a name="GimpZoomPreview-struct"></a>GimpZoomPreview</h3>
120
<a class="indexterm" name="id2710674"></a><pre class="programlisting">typedef struct _GimpZoomPreview GimpZoomPreview;</pre>
126
<div class="refsect2" lang="en">
127
<a name="id2710691"></a><h3>
128
<a name="gimp-zoom-preview-new"></a>gimp_zoom_preview_new ()</h3>
129
<a class="indexterm" name="id2710704"></a><pre class="programlisting">GtkWidget* gimp_zoom_preview_new (<a href="libgimp-gimpdrawable.html#GimpDrawable">GimpDrawable</a> *drawable);</pre>
131
Creates a new <a href="GimpZoomPreview.html" title="GimpZoomPreview"><span class="type">GimpZoomPreview</span></a> widget for <em class="parameter"><code>drawable</code></em>.</p>
135
<div class="variablelist"><table border="0">
136
<col align="left" valign="top">
139
<td><span class="term"><em class="parameter"><code>drawable</code></em> :</span></td>
140
<td> a <a href="libgimp-gimpdrawable.html#GimpDrawable"><span class="type">GimpDrawable</span></a>
144
<td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td>
152
<p class="since">Since GIMP 2.4
156
<div class="refsect2" lang="en">
157
<a name="id2715380"></a><h3>
158
<a name="gimp-zoom-preview-new-with-model"></a>gimp_zoom_preview_new_with_model ()</h3>
159
<a class="indexterm" name="id2715394"></a><pre class="programlisting">GtkWidget* gimp_zoom_preview_new_with_model (<a href="libgimp-gimpdrawable.html#GimpDrawable">GimpDrawable</a> *drawable,
160
GimpZoomModel *model);</pre>
162
Creates a new <a href="GimpZoomPreview.html" title="GimpZoomPreview"><span class="type">GimpZoomPreview</span></a> widget for <em class="parameter"><code>drawable</code></em> using the
163
given <em class="parameter"><code>model</code></em>.
166
This variant of <a href="GimpZoomPreview.html#gimp-zoom-preview-new"><code class="function">gimp_zoom_preview_new()</code></a> allows you to create a
167
preview using an existing zoom model. This may be useful if for
168
example you want to have two zoom previews that keep their zoom
173
<div class="variablelist"><table border="0">
174
<col align="left" valign="top">
177
<td><span class="term"><em class="parameter"><code>drawable</code></em> :</span></td>
178
<td> a <a href="libgimp-gimpdrawable.html#GimpDrawable"><span class="type">GimpDrawable</span></a>
182
<td><span class="term"><em class="parameter"><code>model</code></em> :</span></td>
183
<td> a <span class="type">GimpZoomModel</span>
187
<td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td>
195
<p class="since">Since GIMP 2.4
199
<div class="refsect2" lang="en">
200
<a name="id2715532"></a><h3>
201
<a name="gimp-zoom-preview-get-source"></a>gimp_zoom_preview_get_source ()</h3>
202
<a class="indexterm" name="id2715546"></a><pre class="programlisting">guchar* gimp_zoom_preview_get_source (<a href="GimpZoomPreview.html" title="GimpZoomPreview">GimpZoomPreview</a> *preview,
207
Returns the scaled image data of the part of the drawable the
208
<a href="GimpZoomPreview.html" title="GimpZoomPreview"><span class="type">GimpZoomPreview</span></a> is currently showing, as a newly allocated array of guchar.
209
This function also allow to get the current width, height and bpp of the
210
<a href="GimpZoomPreview.html" title="GimpZoomPreview"><span class="type">GimpZoomPreview</span></a>.</p>
214
<div class="variablelist"><table border="0">
215
<col align="left" valign="top">
218
<td><span class="term"><em class="parameter"><code>preview</code></em> :</span></td>
219
<td> a <a href="GimpZoomPreview.html" title="GimpZoomPreview"><span class="type">GimpZoomPreview</span></a> widget
223
<td><span class="term"><em class="parameter"><code>width</code></em> :</span></td>
224
<td> a pointer to an int where the current width of the zoom widget
229
<td><span class="term"><em class="parameter"><code>height</code></em> :</span></td>
230
<td> a pointer to an int where the current width of the zoom widget
235
<td><span class="term"><em class="parameter"><code>bpp</code></em> :</span></td>
236
<td> return location for the number of bytes per pixel
240
<td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td>
241
<td> newly allocated data that should be released using <code class="function">g_free()</code>
242
when it is not any longer needed
248
<p class="since">Since GIMP 2.4
252
<div class="refsect2" lang="en">
253
<a name="id2712034"></a><h3>
254
<a name="gimp-zoom-preview-get-drawable"></a>gimp_zoom_preview_get_drawable ()</h3>
255
<a class="indexterm" name="id2712047"></a><pre class="programlisting"><a href="libgimp-gimpdrawable.html#GimpDrawable">GimpDrawable</a>* gimp_zoom_preview_get_drawable (<a href="GimpZoomPreview.html" title="GimpZoomPreview">GimpZoomPreview</a> *preview);</pre>
257
Returns the <a href="libgimp-gimpdrawable.html#GimpDrawable"><span class="type">GimpDrawable</span></a> the <a href="GimpZoomPreview.html" title="GimpZoomPreview"><span class="type">GimpZoomPreview</span></a> is attached to.</p>
261
<div class="variablelist"><table border="0">
262
<col align="left" valign="top">
265
<td><span class="term"><em class="parameter"><code>preview</code></em> :</span></td>
266
<td> a <a href="GimpZoomPreview.html" title="GimpZoomPreview"><span class="type">GimpZoomPreview</span></a> widget
270
<td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td>
271
<td> the <a href="libgimp-gimpdrawable.html#GimpDrawable"><span class="type">GimpDrawable</span></a> that was passed to <a href="GimpZoomPreview.html#gimp-zoom-preview-new"><code class="function">gimp_zoom_preview_new()</code></a>.
277
<p class="since">Since GIMP 2.4
281
<div class="refsect2" lang="en">
282
<a name="id2716592"></a><h3>
283
<a name="gimp-zoom-preview-get-factor"></a>gimp_zoom_preview_get_factor ()</h3>
284
<a class="indexterm" name="id2716605"></a><pre class="programlisting">gdouble gimp_zoom_preview_get_factor (<a href="GimpZoomPreview.html" title="GimpZoomPreview">GimpZoomPreview</a> *preview);</pre>
286
Returns the zoom factor the preview is currently using.</p>
290
<div class="variablelist"><table border="0">
291
<col align="left" valign="top">
294
<td><span class="term"><em class="parameter"><code>preview</code></em> :</span></td>
295
<td> a <a href="GimpZoomPreview.html" title="GimpZoomPreview"><span class="type">GimpZoomPreview</span></a> widget
299
<td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td>
300
<td> the current zoom factor
306
<p class="since">Since GIMP 2.4
310
<div class="refsect2" lang="en">
311
<a name="id2716672"></a><h3>
312
<a name="gimp-zoom-preview-get-model"></a>gimp_zoom_preview_get_model ()</h3>
313
<a class="indexterm" name="id2716684"></a><pre class="programlisting">GimpZoomModel* gimp_zoom_preview_get_model (<a href="GimpZoomPreview.html" title="GimpZoomPreview">GimpZoomPreview</a> *preview);</pre>
315
Returns the <span class="type">GimpZoomModel</span> the preview is using.</p>
319
<div class="variablelist"><table border="0">
320
<col align="left" valign="top">
323
<td><span class="term"><em class="parameter"><code>preview</code></em> :</span></td>
324
<td> a <a href="GimpZoomPreview.html" title="GimpZoomPreview"><span class="type">GimpZoomPreview</span></a> widget
328
<td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td>
329
<td> a pointer to the <span class="type">GimpZoomModel</span> owned by the <em class="parameter"><code>preview</code></em>
335
<p class="since">Since GIMP 2.4
339
<div class="refsect1" lang="en">
340
<a name="id2716769"></a><h2>Property Details</h2>
341
<div class="refsect2" lang="en">
342
<a name="id2716778"></a><h3>
343
<a name="GimpZoomPreview--drawable"></a>The "<code class="literal">drawable</code>" property</h3>
344
<a class="indexterm" name="id2716790"></a><pre class="programlisting"> "drawable" gpointer : Read / Write / Construct Only</pre>
346
The drawable the <a href="GimpZoomPreview.html" title="GimpZoomPreview"><span class="type">GimpZoomPreview</span></a> is attached to.</p>
354
<div class="refsect2" lang="en">
355
<a name="id2716825"></a><h3>
356
<a name="GimpZoomPreview--model"></a>The "<code class="literal">model</code>" property</h3>
357
<a class="indexterm" name="id2716837"></a><pre class="programlisting"> "model" GimpZoomModel : Read / Write / Construct Only</pre>
359
The <span class="type">GimpZoomModel</span> used by this <a href="GimpZoomPreview.html" title="GimpZoomPreview"><span class="type">GimpZoomPreview</span></a>.</p>