[789:7] extends: object
Generated low-level callback wrapper for GIR callback match-selected.
EntryCompletionMatchselectedCallback (callback Fn, UserData = null)
Creates one native callback wrapper. The wrapper owns a trampoline that converts native pointers into generated wrapper objects before invoking
Fn.
Fn is the Aussom callback implementation.UserData is retained and passed through to Fn on each invocation when provided.trampoline (nativeSelf, model, iter, nativeUserData)
Internal trampoline. Converts native pointer arguments into generated wrapper instances, then invokes the user's callback.
callback ()
Returns the wrapped NativeCallback.
handle ()
Returns the callback as a NativeHandle.
close ()
Closes the underlying NativeCallback.
isClosed ()
Returns true when the callback has been closed.
[860:7] extends: object
Generated low-level callback wrapper for GIR callback no-matches.
EntryCompletionNomatchesCallback (callback Fn, UserData = null)
Creates one native callback wrapper. The wrapper owns a trampoline that converts native pointers into generated wrapper objects before invoking
Fn.
Fn is the Aussom callback implementation.UserData is retained and passed through to Fn on each invocation when provided.trampoline (nativeSelf, nativeUserData)
Internal trampoline. Converts native pointer arguments into generated wrapper instances, then invokes the user's callback.
callback ()
Returns the wrapped NativeCallback.
handle ()
Returns the callback as a NativeHandle.
close ()
Closes the underlying NativeCallback.
isClosed ()
Returns true when the callback has been closed.
[719:7] extends: object
Generated low-level callback wrapper for GIR callback insert-prefix.
EntryCompletionInsertprefixCallback (callback Fn, UserData = null)
Creates one native callback wrapper. The wrapper owns a trampoline that converts native pointers into generated wrapper objects before invoking
Fn.
Fn is the Aussom callback implementation.UserData is retained and passed through to Fn on each invocation when provided.trampoline (nativeSelf, prefix, nativeUserData)
Internal trampoline. Converts native pointer arguments into generated wrapper instances, then invokes the user's callback.
callback ()
Returns the wrapped NativeCallback.
handle ()
Returns the callback as a NativeHandle.
close ()
Closes the underlying NativeCallback.
isClosed ()
Returns true when the callback has been closed.
[930:14] static extends: object
Generated metadata helpers for EntryCompletion class surfaces.
properties ()
Returns property metadata for
EntryCompletion.
A list.signals ()
Returns signal metadata for
EntryCompletion.
A list.[41:7] extends: object
GtkEntryCompletion is an auxiliary object to provide completion
functionality for GtkEntry. It implements the [iface@Gtk.CellLayout]
interface, to allow the user to add extra cells to the GtkTreeView with
completion matches. “Completion functionality” means that when the user
modifies the text in the entry, GtkEntryCompletion checks which rows in the
model match the current content of the entry, and displays a list of matches.
By default, the matching is done by comparing the entry text
case-insensitively against the text column of the model (see
[method@Gtk.EntryCompletion.set_text_column]), but this can be overridden
with a custom match function (see
[method@Gtk.EntryCompletion.set_match_func]). When the user selects a
completion, the content of the entry is updated. By default, the content of
the entry is replaced by the text column of the model, but this can be
overridden by connecting to the [signal@Gtk.EntryCompletion::match-selected]
signal and updating the entry in the signal handler. Note that you should
return %TRUE from the signal handler to suppress the default behaviour. To
add completion functionality to an entry, use
[method@Gtk.Entry.set_completion]. GtkEntryCompletion uses a
[class@Gtk.TreeModelFilter] model to represent the subset of the entire model
that is currently matching. While the GtkEntryCompletion signals
[signal@Gtk.EntryCompletion::match-selected] and
[signal@Gtk.EntryCompletion::cursor-on-match] take the original model and an
iter pointing to that model as arguments, other callbacks and signals (such
as GtkCellLayoutDataFunc or [signal@Gtk.CellArea::apply-attributes)] will
generally take the filter model as argument. As long as you are only calling
[method@Gtk.TreeModel.get], this will make no difference to you. If for some
reason, you need the original model, use
[method@Gtk.TreeModelFilter.get_model]. Don’t forget to use
[method@Gtk.TreeModelFilter.convert_iter_to_child_iter] to obtain a matching
iter.
EntryCompletion (area = null)
Creates a new
GtkEntryCompletionobject.
area is the GtkCellArea used to layout cells.toNativeHandle (Source)
Normalizes a constructor argument into a raw pointer carrier. Accepts a raw NativeHandle, a raw NativeBuffer returned from
fn.call(...), another generated wrapper exposinghandle(), or null. Returns null when the argument carries no pointer.
Source is the raw handle, raw buffer, wrapper, or null.A raw pointer carrier or null when no pointer is present.getLib ()
Returns the opened native library for this generated wrapper.
The opened native library.handle ()
Returns the wrapped NativeHandle.
The wrapped NativeHandle.isNull ()
Returns true when the wrapped handle is null.
A bool.describe ()
Returns a small string for debugging generated wrappers.
A string.asObject ()
Wraps this handle as
Object.
A Object object.asBuildable ()
Wraps this handle as
Buildable.
A Buildable object.asCellLayout ()
Wraps this handle as
CellLayout.
A CellLayout object.connectSignal (string Name, CallbackObj)
Connects one generated callback wrapper to a named signal.
Name is the signal name.CallbackObj is the generated callback wrapper to connect.The connected handler id.disconnectSignalHandler (int HandlerId)
Disconnects one retained signal handler id.
HandlerId is the signal handler id to disconnect.None.setOnCursoronmatch (callback Fn, UserData = null)
Emitted when a match from the cursor is on a match of the list. The default behaviour is to replace the contents of the entry with the contents of the text column in the row pointed to by @iter. Note that
is the model that was passed to [method@Gtk.EntryCompletion.set_model].Fn is the Aussom callback.Fn is called with (EntryCompletion Self, TreeModel Model, object Iter).UserData is retained and passed through to the generated callback wrapper when provided.The connected handler id.setOnInsertprefix (callback Fn, UserData = null)
Emitted when the inline autocompletion is triggered. The default behaviour is to make the entry display the whole prefix and select the newly inserted part. Applications may connect to this signal in order to insert only a smaller part of the @prefix into the entry - e.g. the entry used in the
GtkFileChooserinserts only the part of the prefix up to the next '/'.
Fn is the Aussom callback.Fn is called with (EntryCompletion Self, string Prefix).UserData is retained and passed through to the generated callback wrapper when provided.The connected handler id.setOnMatchselected (callback Fn, UserData = null)
Emitted when a match from the list is selected. The default behaviour is to replace the contents of the entry with the contents of the text column in the row pointed to by @iter. Note that @model is the model that was passed to [method@Gtk.EntryCompletion.set_model].
Fn is the Aussom callback.Fn is called with (EntryCompletion Self, TreeModel Model, object Iter).UserData is retained and passed through to the generated callback wrapper when provided.The connected handler id.setOnNomatches (callback Fn, UserData = null)
Emitted when the filter model has zero number of rows in completion_complete method. In other words when
GtkEntryCompletionis out of suggestions.
Fn is the Aussom callback.Fn is called with (EntryCompletion Self).UserData is retained and passed through to the generated callback wrapper when provided.The connected handler id.getProperty (string Name)
Reads one generated property by name.
setProperty (string Name, Value)
Writes one generated property by name.
setInlinecompletion (bool Value)
Determines whether the common prefix of the possible completions should be inserted automatically in the entry. Note that this requires text-column to be set, even if you are using a custom match function.
Value is the new property value.None.setInlineselection (bool Value)
Determines whether the possible completions on the popup will appear in the entry as you navigate through them.
Value is the new property value.None.setMinimumkeylength (int Value)
The minimum key length as set for completion.
Value is the new property value.None.setModel (object Value)
The model used as data source.
Value is the new property value.None.setPopupcompletion (bool Value)
Determines whether the possible completions should be shown in a popup window.
Value is the new property value.None.setPopupsetwidth (bool Value)
Determines whether the completions popup window will be resized to the width of the entry.
Value is the new property value.None.setPopupsinglematch (bool Value)
Determines whether the completions popup window will shown for a single possible completion. You probably want to set this to %FALSE if you are using [property@Gtk.EntryCompletion:inline-completion].
Value is the new property value.None.setTextcolumn (int Value)
The column of the model containing the strings. Note that the strings must be UTF-8.
Value is the new property value.None.complete ()
Requests a completion operation, or in other words a refiltering of the current list with completions, using the current key. The completion list view will be updated accordingly.
None.compute_prefix (string key)
Computes the common prefix that is shared by all rows in @completion that start with @key. If no row matches @key, %NULL will be returned. Note that a text column must have been set for this function to work, see [method@Gtk.EntryCompletion.set_text_column] for details.
key is The text to complete for.get_completion_prefix ()
Get the original text entered by the user that triggered the completion or %NULL if there’s no completion ongoing.
get_entry ()
Gets the entry @completion has been attached to.
get_inline_completion ()
Returns whether the common prefix of the possible completions should be automatically inserted in the entry.
get_inline_selection ()
Returns %TRUE if inline-selection mode is turned on.
get_minimum_key_length ()
Returns the minimum key length as set for @completion.
get_model ()
Returns the model the
GtkEntryCompletionis using as data source. Returns %NULL if the model is unset.
get_popup_completion ()
Returns whether the completions should be presented in a popup window.
get_popup_set_width ()
Returns whether the completion popup window will be resized to the width of the entry.
get_popup_single_match ()
Returns whether the completion popup window will appear even if there is only a single match.
get_text_column ()
Returns the column in the model of @completion to get strings from.
insert_prefix ()
Requests a prefix insertion.
None.set_inline_completion (bool inline_completion)
Sets whether the common prefix of the possible completions should be automatically inserted in the entry.
inline_completion is %TRUE to do inline completion.None.set_inline_selection (bool inline_selection)
Sets whether it is possible to cycle through the possible completions inside the entry.
inline_selection is %TRUE to do inline selection.None.set_minimum_key_length (int length)
Requires the length of the search key for @completion to be at least
This is useful for long lists, where completing using a small key takes a lot of time and will come up with meaningless results anyway (ie, a too large dataset).length is the minimum length of the key in order to start completing.None.set_model (object model)
Sets the model for a
GtkEntryCompletion. If @completion already has a model set, it will remove it before setting the new model. If model is %NULL, then it will unset the model.
model is the GtkTreeModel.None.set_popup_completion (bool popup_completion)
Sets whether the completions should be presented in a popup window.
popup_completion is %TRUE to do popup completion.None.set_popup_set_width (bool popup_set_width)
Sets whether the completion popup window will be resized to be the same width as the entry.
popup_set_width is %TRUE to make the width of the popup the same as the entry.None.set_popup_single_match (bool popup_single_match)
Sets whether the completion popup window will appear even if there is only a single match. You may want to set this to %FALSE if you are using [property@Gtk.EntryCompletion:inline-completion].
popup_single_match is %TRUE if the popup should appear even for a single match.None.set_text_column (int column)
Convenience function for setting up the most used case of this code: a completion list with just strings. This function will set up @completion to have a list displaying all (and just) strings in the completion list, and to get those strings from @column in the model of @completion. This functions creates and adds a
GtkCellRendererTextfor the selected column. If you need to set the text column, but don't want the cell renderer, use g_object_set() to set the [property@Gtk.EntryCompletion:text-column] property directly.
column is the column in the model of @completion to get strings from.None.[648:7] extends: object
Generated low-level callback wrapper for GIR callback cursor-on-match.
EntryCompletionCursoronmatchCallback (callback Fn, UserData = null)
Creates one native callback wrapper. The wrapper owns a trampoline that converts native pointers into generated wrapper objects before invoking
Fn.
Fn is the Aussom callback implementation.UserData is retained and passed through to Fn on each invocation when provided.trampoline (nativeSelf, model, iter, nativeUserData)
Internal trampoline. Converts native pointer arguments into generated wrapper instances, then invokes the user's callback.
callback ()
Returns the wrapped NativeCallback.
handle ()
Returns the callback as a NativeHandle.
close ()
Closes the underlying NativeCallback.
isClosed ()
Returns true when the callback has been closed.