]> Pileus Git - ~andy/gtk/blob - docs/reference/gtk/tmpl/gtkselection.sgml
fixed wording and typos in some places. added a new section "Optimizing RC
[~andy/gtk] / docs / reference / gtk / tmpl / gtkselection.sgml
1 <!-- ##### SECTION Title ##### -->
2 Selections
3
4 <!-- ##### SECTION Short_Description ##### -->
5 Functions for handling inter-process communication via selections
6
7 <!-- ##### SECTION Long_Description ##### -->
8
9 <para>
10 The selection mechanism provides the basis for different types
11 of communication between processes. In particular, drag and drop and
12 #GtkClipboard work via selections. You will very seldom or
13 never need to use most of the functions in this section directly;
14 #GtkClipboard provides a nicer interface to the same functionality.
15 </para>
16 <para>
17 Some of the datatypes defined this section are used in
18 the #GtkClipboard and drag-and-drop API's as well. The
19 #GtkTargetEntry structure and #GtkTargetList objects represent
20 lists of data types that are supported when sending or
21 receiving data. The #GtkSelectionData object is used to
22 store a chunk of data along with the data type and other
23 associated information.
24 </para>
25
26 <!-- ##### SECTION See_Also ##### -->
27 <para>
28 <variablelist>
29
30 <varlistentry>
31 <term>#GtkWidget</term>
32 <listitem><para>Much of the operation of selections happens via
33              signals for #GtkWidget. In particular, if you are
34              using the functions in this section, you may need
35              to pay attention to ::selection_get,
36              ::selection_received,  and :selection_clear_event
37              signals.</para></listitem>
38 </varlistentry>
39
40 </variablelist>
41
42 </para>
43
44 <!-- ##### SECTION Stability_Level ##### -->
45
46
47 <!-- ##### STRUCT GtkTargetEntry ##### -->
48 <para>
49 A #GtkTargetEntry structure represents a single type of
50 data than can be supplied for by a widget for a selection
51 or for supplied or received during drag-and-drop. It 
52 contains a string representing the drag type, a flags
53 field (used only for drag and drop - see #GtkTargetFlags),
54 and an application assigned integer ID. The integer
55 ID will later be passed as a signal parameter for signals
56 like "selection_get". It allows the application to identify
57 the target type without extensive string compares.
58 </para>
59
60 @target: 
61 @flags: 
62 @info: 
63
64 <!-- ##### STRUCT GtkTargetList ##### -->
65 <para>
66 A #GtkTargetList structure is a reference counted list
67 of #GtkTargetPair. It is used to represent the same
68 information as a table of #GtkTargetEntry, but in
69 an efficient form. This structure should be treated as
70 opaque.
71 </para>
72
73 @list: 
74 @ref_count: 
75
76 <!-- ##### STRUCT GtkTargetPair ##### -->
77 <para>
78 Internally used structure in the drag-and-drop and 
79 selection handling code.
80 </para>
81
82 @target: 
83 @flags: 
84 @info: 
85
86 <!-- ##### FUNCTION gtk_target_list_new ##### -->
87 <para>
88 </para>
89
90 @targets: 
91 @ntargets: 
92 @Returns: 
93
94
95 <!-- ##### FUNCTION gtk_target_list_ref ##### -->
96 <para>
97 </para>
98
99 @list: 
100
101
102 <!-- ##### FUNCTION gtk_target_list_unref ##### -->
103 <para>
104 </para>
105
106 @list: 
107
108
109 <!-- ##### FUNCTION gtk_target_list_add ##### -->
110 <para>
111 </para>
112
113 @list: 
114 @target: 
115 @flags: 
116 @info: 
117
118
119 <!-- ##### FUNCTION gtk_target_list_add_table ##### -->
120 <para>
121 </para>
122
123 @list: 
124 @targets: 
125 @ntargets: 
126
127
128 <!-- ##### FUNCTION gtk_target_list_add_text_targets ##### -->
129 <para>
130
131 </para>
132
133 @list: 
134 @info: 
135
136
137 <!-- ##### FUNCTION gtk_target_list_add_image_targets ##### -->
138 <para>
139
140 </para>
141
142 @list: 
143 @info: 
144 @writable: 
145
146
147 <!-- ##### FUNCTION gtk_target_list_add_uri_targets ##### -->
148 <para>
149
150 </para>
151
152 @list: 
153 @info: 
154
155
156 <!-- ##### FUNCTION gtk_target_list_remove ##### -->
157 <para>
158 </para>
159
160 @list: 
161 @target: 
162
163
164 <!-- ##### FUNCTION gtk_target_list_find ##### -->
165 <para>
166 </para>
167
168 @list: 
169 @target: 
170 @info: 
171 @Returns: 
172
173
174 <!-- ##### FUNCTION gtk_selection_owner_set ##### -->
175 <para>
176 </para>
177
178 @widget: 
179 @selection: 
180 @time_: 
181 @Returns: 
182
183
184 <!-- ##### FUNCTION gtk_selection_owner_set_for_display ##### -->
185 <para>
186
187 </para>
188
189 @display: 
190 @widget: 
191 @selection: 
192 @time_: 
193 @Returns: 
194
195
196 <!-- ##### FUNCTION gtk_selection_add_target ##### -->
197 <para>
198 </para>
199
200 @widget: 
201 @selection: 
202 @target: 
203 @info: 
204
205
206 <!-- ##### FUNCTION gtk_selection_add_targets ##### -->
207 <para>
208 </para>
209
210 @widget: 
211 @selection: 
212 @targets: 
213 @ntargets: 
214
215
216 <!-- ##### FUNCTION gtk_selection_clear_targets ##### -->
217 <para>
218
219 </para>
220
221 @widget: 
222 @selection: 
223
224
225 <!-- ##### FUNCTION gtk_selection_convert ##### -->
226 <para>
227 </para>
228
229 @widget: 
230 @selection: 
231 @target: 
232 @time_: 
233 @Returns: x
234
235
236 <!-- ##### FUNCTION gtk_selection_data_set ##### -->
237 <para>
238 </para>
239
240 @selection_data: 
241 @type: 
242 @format: 
243 @data: 
244 @length: 
245
246
247 <!-- ##### FUNCTION gtk_selection_data_set_text ##### -->
248 <para>
249
250 </para>
251
252 @selection_data: 
253 @str: 
254 @len: 
255 @Returns: 
256
257
258 <!-- ##### FUNCTION gtk_selection_data_get_text ##### -->
259 <para>
260
261 </para>
262
263 @selection_data: 
264 @Returns: 
265
266
267 <!-- ##### FUNCTION gtk_selection_data_set_pixbuf ##### -->
268 <para>
269
270 </para>
271
272 @selection_data: 
273 @pixbuf: 
274 @Returns: 
275
276
277 <!-- ##### FUNCTION gtk_selection_data_get_pixbuf ##### -->
278 <para>
279
280 </para>
281
282 @selection_data: 
283 @Returns: 
284
285
286 <!-- ##### FUNCTION gtk_selection_data_set_uris ##### -->
287 <para>
288
289 </para>
290
291 @selection_data: 
292 @uris: 
293 @Returns: 
294
295
296 <!-- ##### FUNCTION gtk_selection_data_get_uris ##### -->
297 <para>
298
299 </para>
300
301 @selection_data: 
302 @Returns: 
303
304
305 <!-- ##### FUNCTION gtk_selection_data_get_targets ##### -->
306 <para>
307
308 </para>
309
310 @selection_data: 
311 @targets: 
312 @n_atoms: 
313 @Returns: 
314
315
316 <!-- ##### FUNCTION gtk_selection_data_targets_include_image ##### -->
317 <para>
318
319 </para>
320
321 @selection_data: 
322 @writable: 
323 @Returns: 
324
325
326 <!-- ##### FUNCTION gtk_selection_data_targets_include_text ##### -->
327 <para>
328
329 </para>
330
331 @selection_data: 
332 @Returns: 
333
334
335 <!-- ##### FUNCTION gtk_selection_data_targets_include_uri ##### -->
336 <para>
337
338 </para>
339
340 @selection_data: 
341 @Returns: 
342
343
344 <!-- ##### FUNCTION gtk_targets_include_image ##### -->
345 <para>
346
347 </para>
348
349 @targets: 
350 @n_targets: 
351 @writable: 
352 @Returns: 
353
354
355 <!-- ##### FUNCTION gtk_targets_include_text ##### -->
356 <para>
357
358 </para>
359
360 @targets: 
361 @n_targets: 
362 @Returns: 
363
364
365 <!-- ##### FUNCTION gtk_targets_include_uri ##### -->
366 <para>
367
368 </para>
369
370 @targets: 
371 @n_targets: 
372 @Returns: 
373
374
375 <!-- ##### FUNCTION gtk_selection_remove_all ##### -->
376 <para>
377 </para>
378
379 @widget: 
380
381
382 <!-- ##### FUNCTION gtk_selection_clear ##### -->
383 <para>
384 </para>
385
386 @widget: 
387 @event: 
388 @Returns: 
389
390
391 <!-- ##### FUNCTION gtk_selection_data_copy ##### -->
392 <para>
393 </para>
394
395 @data: 
396 @Returns: 
397
398
399 <!-- ##### FUNCTION gtk_selection_data_free ##### -->
400 <para>
401 </para>
402
403 @data: 
404
405