Add gdk-add-client-message-filter
[cl-gtk2.git] / doc / gtk.interfaces.texi
blob238e0755c2bab3ed8c2561a60d780a7e30ede47f
1 @menu
2 * activatable::
3 * atk-implementor-iface::
4 * buildable::
5 * cell-editable::
6 * cell-layout::
7 * editable::
8 * file-chooser::
9 * file-chooser-embed::
10 * orientable::
11 * print-operation-preview::
12 * recent-chooser::
13 * tool-shell::
14 * tree-drag-dest::
15 * tree-drag-source::
16 * tree-model::
17 * tree-sortable::
18 @end menu
20 @node activatable
21 @section activatable
22 @Class activatable
25 Slots:
26 @itemize
27 @item @anchor{slot.activatable.related-action}related-action. Type: @ref{action}. Accessor: @anchor{fn.activatable-related-action}@code{activatable-related-action}.
28 @item @anchor{slot.activatable.use-action-appearance}use-action-appearance. Type: @code{boolean}. Accessor: @anchor{fn.activatable-use-action-appearance}@code{activatable-use-action-appearance}.
29 @end itemize
32 Signals:
33 @itemize
34 @end itemize
37 @node atk-implementor-iface
38 @section atk-implementor-iface
39 @Class atk-implementor-iface
42 Slots:
43 @itemize
44 @end itemize
47 Signals:
48 @itemize
49 @end itemize
52 @node buildable
53 @section buildable
54 @Class buildable
57 Slots:
58 @itemize
59 @end itemize
62 Signals:
63 @itemize
64 @end itemize
67 @node cell-editable
68 @section cell-editable
69 @Class cell-editable
72 Slots:
73 @itemize
74 @end itemize
77 Signals:
78 @itemize
79 @item @anchor{signal.cell-editable.editing-done}"editing-done". Signature: (instance @ref{cell-editable}) @result{} void. Options: run-last.
80 @item @anchor{signal.cell-editable.remove-widget}"remove-widget". Signature: (instance @ref{cell-editable}) @result{} void. Options: run-last.
81 @end itemize
84 @node cell-layout
85 @section cell-layout
86 @Class cell-layout
89 Slots:
90 @itemize
91 @end itemize
94 Signals:
95 @itemize
96 @end itemize
99 @node editable
100 @section editable
101 @Class editable
103 The @ref{editable} interface is an interface which should be implemented by text editing widgets, such as @ref{entry}. It contains functions for generically manipulating an editable widget, a large number of action signals used for key bindings, and several signals that an application can connect to to modify the behavior of a widget.
105 Slots:
106 @itemize
107 @item @anchor{slot.editable.editable}editable. Type: @code{boolean}. Accessor: @anchor{fn.editable-editable}@code{editable-editable}.
109 Whether the user can edit the text in the editable widget or not.
110 @item @anchor{slot.editable.position}position. Type: @code{integer}. Accessor: @anchor{fn.editable-position}@code{editable-position}.
112 The cursor position in the editable.
114 The cursor is displayed before the character with the given (base 0) index in the contents of the editable. The value must be less than or equal to the number of characters in the editable. A value of -1 indicates that the position should be set after the last character of the editable. Note that position is in characters, not in bytes.
115 @end itemize
118 Signals:
119 @itemize
120 @item @anchor{signal.editable.changed}"changed". Signature: (instance @ref{editable}) @result{} void. Options: run-last.
122 This signal is emitted at the end of a single user-visible operation on the contents of the @ref{editable}.
124 E.g., a paste operation that replaces the contents of the selection will cause only one signal emission (even though it is implemented by first deleting the selection, then inserting the new content, and may cause multiple @code{::notify::text} signals to be emitted).
125 @item @anchor{signal.editable.delete-text}"delete-text". Signature: (instance @ref{editable}), (starting-position @code{integer}), (end-position @code{integer}) @result{} void. Options: run-last.
127 This signal is emitted when text is deleted from the widget by the user. The default handler for this signal will normally be responsible for deleting the text, so by connecting to this signal and then stopping the signal with @code{g_signal_stop_emission} (TODO), it is possible to modify the range of deleted text, or prevent it from being deleted entirely. The start_pos and end_pos parameters are interpreted as for @ref{editable-delete-text}.
128 @item @anchor{signal.editable.insert-text}"insert-text". Signature: (instance @ref{editable}), (new-text @code{string}), (new-text-length @code{integer}), (position gpointer) @result{} void. Options: run-last.
130 This signal is emitted when text is inserted into the widget by the user. The default handler for this signal will normally be responsible for inserting the text, so by connecting to this signal and then stopping the signal with g_signal_stop_emission(), it is possible to modify the inserted text, or prevent it from being inserted entirely.
132 @var{position}: a pointer to the position (of the CFFI foreign type @code{:integer}), in characters, at which to insert the new text. After the signal emission is finished, it should point after the newly inserted text.
133 @end itemize
135 @RMethod editable-select-region
136 @lisp
137 (editable-select-region editable start end)
138 @end lisp
140 Selects a region of text in @var{editable}. The characters that are selected are those characters at positions from @var{start} (an integer) up to, but not including @var{end} (an integer). If @var{end} is negative, then the the characters selected are those characters from @var{start} to the end of the text.
142 Note that positions are specified in characters, not bytes.
144 @RMethod editable-selection
145 @lisp
146 (editable-selection editable) @result{} (values selected-p start end)
147 @end lisp
149 Retrieves the selection bounds of the @var{editable}. @var{selected-p} is a @code{boolean} specifying whether there is a selection, @var{start} is the start of the selection and @var{end} is the end of the selection. If no text was selected, @var{start} and @var{end} will be identical and @var{selected-p} will be @code{NIL}.
151 Note that positions are specified in characters, not bytes.
153 @RMethod editable-insert-text
154 @lisp
155 (editable-insert-text editable text position) @result{} new-position
156 @end lisp
158 Inserts the @var{text} (a string) into the contents of the @var{editable}, at position specified by @var{position} (an integer). Returns the position after the inserted text.
160 Note that the position is in characters, not in bytes.
162 @RMethod editable-delete-text
163 @lisp
164 (editable-delete-text editable start end)
165 @end lisp
167 Deletes a sequence of characters. The characters that are deleted are those characters at positions from @var{start} up to, but not including @var{end}. If @var{end} is negative, then the the characters deleted are those from @var{start} to the end of the text.
169 Note that the positions are specified in characters, not bytes.
171 @RMethod editable-get-chars
172 @lisp
173 (editable-get-chars editable &key (start 0) (end -1)) @result{} string
174 @end lisp
176 Retrieves a substring from @var{editable} contents. The characters that are retrieved are those characters at positions from @var{start} up to, but not including @var{end}. If @var{end} is negative, then the the characters retrieved are those characters from @var{start} to the end of the text.
178 @RMethod editable-cut-clipboard
179 @lisp
180 (editable-cut-clipboard editable)
181 @end lisp
183 Removes the contents of the currently selected content in the @var{editable} and puts it on the clipboard.
185 @RMethod editable-copy-clipboard
186 @lisp
187 (editable-copy-clipboard editable)
188 @end lisp
190 Copies the contents of the currently selected content in the @var{editable} and puts it on the clipboard.
192 @RMethod editable-paste-clipboard
193 @lisp
194 (editable-paste-clipboard editable)
195 @end lisp
197 Pastes the content of the clipboard to the current position of the cursor in the @var{editable}.
200 @node file-chooser
201 @section file-chooser
202 @Class file-chooser
205 Slots:
206 @itemize
207 @item @anchor{slot.file-chooser.action}action. Type: @ref{file-chooser-action}. Accessor: @anchor{fn.file-chooser-action}@code{file-chooser-action}.
208 @item @anchor{slot.file-chooser.current-folder}current-folder. Type: @code{string}. Accessor: @anchor{fn.file-chooser-current-folder}@code{file-chooser-current-folder}.
209 @item @anchor{slot.file-chooser.current-folder-uri}current-folder-uri. Type: @code{string}. Accessor: @anchor{fn.file-chooser-current-folder-uri}@code{file-chooser-current-folder-uri}.
210 @item @anchor{slot.file-chooser.current-name}current-name. Type: @code{string}. Accessor: @anchor{fn.file-chooser-current-name}@code{file-chooser-current-name}. Write-only.
211 @item @anchor{slot.file-chooser.do-overwrite-confirmation}do-overwrite-confirmation. Type: @code{boolean}. Accessor: @anchor{fn.file-chooser-do-overwrite-confirmation}@code{file-chooser-do-overwrite-confirmation}.
212 @item @anchor{slot.file-chooser.extra-widget}extra-widget. Type: @ref{widget}. Accessor: @anchor{fn.file-chooser-extra-widget}@code{file-chooser-extra-widget}.
213 @item @anchor{slot.file-chooser.file-system-backend}file-system-backend. Type: @code{string}. Accessor: @anchor{fn.file-chooser-file-system-backend}@code{file-chooser-file-system-backend}. Write-only.
214 @item @anchor{slot.file-chooser.filename}filename. Type: @code{string}. Accessor: @anchor{fn.file-chooser-filename}@code{file-chooser-filename}.
215 @item @anchor{slot.file-chooser.filter}filter. Type: @ref{file-filter}. Accessor: @anchor{fn.file-chooser-filter}@code{file-chooser-filter}.
216 @item @anchor{slot.file-chooser.local-only}local-only. Type: @code{boolean}. Accessor: @anchor{fn.file-chooser-local-only}@code{file-chooser-local-only}.
217 @item @anchor{slot.file-chooser.preview-filename}preview-filename. Type: @code{string}. Accessor: @anchor{fn.file-chooser-preview-filename}@code{file-chooser-preview-filename}. Read-only.
218 @item @anchor{slot.file-chooser.preview-uri}preview-uri. Type: @code{string}. Accessor: @anchor{fn.file-chooser-preview-uri}@code{file-chooser-preview-uri}. Read-only.
219 @item @anchor{slot.file-chooser.preview-widget}preview-widget. Type: @ref{widget}. Accessor: @anchor{fn.file-chooser-preview-widget}@code{file-chooser-preview-widget}.
220 @item @anchor{slot.file-chooser.preview-widget-active}preview-widget-active. Type: @code{boolean}. Accessor: @anchor{fn.file-chooser-preview-widget-active}@code{file-chooser-preview-widget-active}.
221 @item @anchor{slot.file-chooser.select-multiple}select-multiple. Type: @code{boolean}. Accessor: @anchor{fn.file-chooser-select-multiple}@code{file-chooser-select-multiple}.
222 @item @anchor{slot.file-chooser.show-hidden}show-hidden. Type: @code{boolean}. Accessor: @anchor{fn.file-chooser-show-hidden}@code{file-chooser-show-hidden}.
223 @item @anchor{slot.file-chooser.uri}uri. Type: @code{string}. Accessor: @anchor{fn.file-chooser-uri}@code{file-chooser-uri}.
224 @item @anchor{slot.file-chooser.use-preview-label}use-preview-label. Type: @code{boolean}. Accessor: @anchor{fn.file-chooser-use-preview-label}@code{file-chooser-use-preview-label}.
225 @end itemize
228 Signals:
229 @itemize
230 @item @anchor{signal.file-chooser.confirm-overwrite}"confirm-overwrite". Signature: (instance @ref{file-chooser}) @result{} @ref{file-chooser-confirmation}. Options: run-last.
231 @item @anchor{signal.file-chooser.current-folder-changed}"current-folder-changed". Signature: (instance @ref{file-chooser}) @result{} void. Options: run-last.
232 @item @anchor{signal.file-chooser.file-activated}"file-activated". Signature: (instance @ref{file-chooser}) @result{} void. Options: run-last.
233 @item @anchor{signal.file-chooser.selection-changed}"selection-changed". Signature: (instance @ref{file-chooser}) @result{} void. Options: run-last.
234 @item @anchor{signal.file-chooser.update-preview}"update-preview". Signature: (instance @ref{file-chooser}) @result{} void. Options: run-last.
235 @end itemize
238 @node file-chooser-embed
239 @section file-chooser-embed
240 @Class file-chooser-embed
243 Slots:
244 @itemize
245 @end itemize
248 Signals:
249 @itemize
250 @item @anchor{signal.file-chooser-embed.default-size-changed}"default-size-changed". Signature: (instance @ref{file-chooser-embed}) @result{} void. Options: run-last.
251 @item @anchor{signal.file-chooser-embed.response-requested}"response-requested". Signature: (instance @ref{file-chooser-embed}) @result{} void. Options: run-last.
252 @end itemize
255 @node orientable
256 @section orientable
257 @Class orientable
260 Slots:
261 @itemize
262 @item @anchor{slot.orientable.orientation}orientation. Type: @ref{orientation}. Accessor: @anchor{fn.orientable-orientation}@code{orientable-orientation}.
263 @end itemize
266 Signals:
267 @itemize
268 @end itemize
271 @node print-operation-preview
272 @section print-operation-preview
273 @Class print-operation-preview
276 Slots:
277 @itemize
278 @end itemize
281 Signals:
282 @itemize
283 @item @anchor{signal.print-operation-preview.got-page-size}"got-page-size". Signature: (instance @ref{print-operation-preview}), (arg-1 @ref{print-context}), (arg-2 @ref{page-setup}) @result{} void. Options: run-last.
284 @item @anchor{signal.print-operation-preview.ready}"ready". Signature: (instance @ref{print-operation-preview}), (arg-1 @ref{print-context}) @result{} void. Options: run-last.
285 @end itemize
288 @node recent-chooser
289 @section recent-chooser
290 @Class recent-chooser
293 Slots:
294 @itemize
295 @item @anchor{slot.recent-chooser.filter}filter. Type: @ref{recent-filter}. Accessor: @anchor{fn.recent-chooser-filter}@code{recent-chooser-filter}.
296 @item @anchor{slot.recent-chooser.limit}limit. Type: @code{integer}. Accessor: @anchor{fn.recent-chooser-limit}@code{recent-chooser-limit}.
297 @item @anchor{slot.recent-chooser.local-only}local-only. Type: @code{boolean}. Accessor: @anchor{fn.recent-chooser-local-only}@code{recent-chooser-local-only}.
298 @item @anchor{slot.recent-chooser.recent-manager}recent-manager. Type: @ref{recent-manager}. Accessor: @anchor{fn.recent-chooser-recent-manager}@code{recent-chooser-recent-manager}. Write-only.
299 @item @anchor{slot.recent-chooser.select-multiple}select-multiple. Type: @code{boolean}. Accessor: @anchor{fn.recent-chooser-select-multiple}@code{recent-chooser-select-multiple}.
300 @item @anchor{slot.recent-chooser.show-icons}show-icons. Type: @code{boolean}. Accessor: @anchor{fn.recent-chooser-show-icons}@code{recent-chooser-show-icons}.
301 @item @anchor{slot.recent-chooser.show-not-found}show-not-found. Type: @code{boolean}. Accessor: @anchor{fn.recent-chooser-show-not-found}@code{recent-chooser-show-not-found}.
302 @item @anchor{slot.recent-chooser.show-private}show-private. Type: @code{boolean}. Accessor: @anchor{fn.recent-chooser-show-private}@code{recent-chooser-show-private}.
303 @item @anchor{slot.recent-chooser.show-tips}show-tips. Type: @code{boolean}. Accessor: @anchor{fn.recent-chooser-show-tips}@code{recent-chooser-show-tips}.
304 @item @anchor{slot.recent-chooser.sort-type}sort-type. Type: @ref{recent-sort-type}. Accessor: @anchor{fn.recent-chooser-sort-type}@code{recent-chooser-sort-type}.
305 @end itemize
308 Signals:
309 @itemize
310 @item @anchor{signal.recent-chooser.item-activated}"item-activated". Signature: (instance @ref{recent-chooser}) @result{} void. Options: run-last.
311 @item @anchor{signal.recent-chooser.selection-changed}"selection-changed". Signature: (instance @ref{recent-chooser}) @result{} void. Options: run-last.
312 @end itemize
315 @node tool-shell
316 @section tool-shell
317 @Class tool-shell
320 Slots:
321 @itemize
322 @end itemize
325 Signals:
326 @itemize
327 @end itemize
330 @node tree-drag-dest
331 @section tree-drag-dest
332 @Class tree-drag-dest
335 Slots:
336 @itemize
337 @end itemize
340 Signals:
341 @itemize
342 @end itemize
345 @node tree-drag-source
346 @section tree-drag-source
347 @Class tree-drag-source
350 Slots:
351 @itemize
352 @end itemize
355 Signals:
356 @itemize
357 @end itemize
360 @node tree-model
361 @section tree-model
362 @Class tree-model
365 Slots:
366 @itemize
367 @end itemize
370 Signals:
371 @itemize
372 @item @anchor{signal.tree-model.row-changed}"row-changed". Signature: (instance @ref{tree-model}), (arg-1 @ref{tree-path}), (arg-2 @ref{tree-iter}) @result{} void. Options: run-last.
373 @item @anchor{signal.tree-model.row-deleted}"row-deleted". Signature: (instance @ref{tree-model}), (arg-1 @ref{tree-path}) @result{} void. Options: run-first.
374 @item @anchor{signal.tree-model.row-has-child-toggled}"row-has-child-toggled". Signature: (instance @ref{tree-model}), (arg-1 @ref{tree-path}), (arg-2 @ref{tree-iter}) @result{} void. Options: run-last.
375 @item @anchor{signal.tree-model.row-inserted}"row-inserted". Signature: (instance @ref{tree-model}), (arg-1 @ref{tree-path}), (arg-2 @ref{tree-iter}) @result{} void. Options: run-first.
376 @item @anchor{signal.tree-model.rows-reordered}"rows-reordered". Signature: (instance @ref{tree-model}), (arg-1 @ref{tree-path}), (arg-2 @ref{tree-iter}), (arg-3 gpointer) @result{} void. Options: run-first.
377 @end itemize
380 @node tree-sortable
381 @section tree-sortable
382 @Class tree-sortable
385 Slots:
386 @itemize
387 @end itemize
390 Signals:
391 @itemize
392 @item @anchor{signal.tree-sortable.sort-column-changed}"sort-column-changed". Signature: (instance @ref{tree-sortable}) @result{} void. Options: run-last.
393 @end itemize