Basics

Guides

API Reference

Menu

Basics

Guides

API Reference

class: ListBoxRowMeta

[428:14] static extends: object

Generated metadata helpers for ListBoxRow class surfaces.

Methods

  • properties ()

    Returns property metadata for ListBoxRow.

    • @r A list.
  • signals ()

    Returns signal metadata for ListBoxRow.

    • @r A list.

class: ListBoxRowActivateCallback

[358:7] extends: object

Generated low-level callback wrapper for GIR callback activate.

Members

  • callbackObj
  • userFn
  • userData
  • hasUserData

Methods

  • ListBoxRowActivateCallback (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.

    • @p Fn is the Aussom callback implementation.
    • @p 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.

class: ListBoxRow

[13:7] extends: object

The kind of widget that can be added to a GtkListBox. [class@Gtk.ListBox] will automatically wrap its children in a GtkListboxRow when necessary.

Members

  • handleObj
  • lib
  • retainedCallbacks
  • signalHandlerNames
  • signalSetterHandlers

Methods

  • ListBoxRow ()

    Creates a new GtkListBoxRow.

  • 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 exposing handle(), or null. Returns null when the argument carries no pointer.

    • @p Source is the raw handle, raw buffer, wrapper, or null.
    • @r A raw pointer carrier or null when no pointer is present.
  • getLib ()

    Returns the opened native library for this generated wrapper.

    • @r The opened native library.
  • handle ()

    Returns the wrapped NativeHandle.

    • @r The wrapped NativeHandle.
  • isNull ()

    Returns true when the wrapped handle is null.

    • @r A bool.
  • describe ()

    Returns a small string for debugging generated wrappers.

    • @r A string.
  • asWidget ()

    Wraps this handle as Widget.

    • @r A Widget object.
  • asAccessible ()

    Wraps this handle as Accessible.

    • @r A Accessible object.
  • asActionable ()

    Wraps this handle as Actionable.

    • @r A Actionable object.
  • asBuildable ()

    Wraps this handle as Buildable.

    • @r A Buildable object.
  • asConstraintTarget ()

    Wraps this handle as ConstraintTarget.

    • @r A ConstraintTarget object.
  • connectSignal (string Name, CallbackObj)

    Connects one generated callback wrapper to a named signal.

    • @p Name is the signal name.
    • @p CallbackObj is the generated callback wrapper to connect.
    • @r The connected handler id.
  • disconnectSignalHandler (int HandlerId)

    Disconnects one retained signal handler id.

    • @p HandlerId is the signal handler id to disconnect.
    • @r None.
  • setOnActivate (callback Fn, UserData = null)

    This is a keybinding signal, which will cause this row to be activated. If you want to be notified when the user activates a row (by key or not), use the [signal@Gtk.ListBox::row-activated] signal on the row’s parent GtkListBox.

    • @p Fn is the Aussom callback.
    • @p Fn is called with (ListBoxRow Self).
    • @p UserData is retained and passed through to the generated callback wrapper when provided.
    • @r The connected handler id.
  • getProperty (string Name)

    Reads one generated property by name.

  • setProperty (string Name, Value)

    Writes one generated property by name.

  • setActivatable (bool Value)

    Determines whether the ::row-activated signal will be emitted for this row.

    • @p Value is the new property value.
    • @r None.
  • setChild (object Value)

    The child widget.

    • @p Value is the new property value.
    • @r None.
  • setSelectable (bool Value)

    Determines whether this row can be selected.

    • @p Value is the new property value.
    • @r None.
  • changed ()

    Marks @row as changed, causing any state that depends on this to be updated. This affects sorting, filtering and headers. Note that calls to this method must be in sync with the data used for the row functions. For instance, if the list is mirroring some external data set, and two rows changed in the external data set then when you call gtk_list_box_row_changed() on the first row the sort function must only read the new data for the first of the two changed rows, otherwise the resorting of the rows will be wrong. This generally means that if you don’t fully control the data model you have to duplicate the data that affects the listbox row functions into the row widgets themselves. Another alternative is to call [method@Gtk.ListBox.invalidate_sort] on any model change, but that is more expensive.

    • @r None.
  • get_activatable ()

    Gets whether the row is activatable.

  • get_child ()

    Gets the child widget of @row.

  • get_header ()

    Returns the current header of the @row. This can be used in a [callback@Gtk.ListBoxUpdateHeaderFunc] to see if there is a header set already, and if so to update the state of it.

  • get_index ()

    Gets the current index of the @row in its GtkListBox container.

  • get_selectable ()

    Gets whether the row can be selected.

  • is_selected ()

    Returns whether the child is currently selected in its GtkListBox container.

  • set_activatable (bool activatable)

    Set whether the row is activatable.

    • @p activatable is %TRUE to mark the row as activatable.
    • @r None.
  • set_child (object child)

    Sets the child widget of @self.

    • @p child is the child widget.
    • @r None.
  • set_header (object header)

    Sets the current header of the @row. This is only allowed to be called from a [callback@Gtk.ListBoxUpdateHeaderFunc]. It will replace any existing header in the row, and be shown in front of the row in the listbox.

    • @p header is the header.
    • @r None.
  • set_selectable (bool selectable)

    Set whether the row can be selected.

    • @p selectable is %TRUE to mark the row as selectable.
    • @r None.