ComboRow

open class ComboRow(pointer: <Error class: unknown class><<Error class: unknown class>>) : ActionRow

A class@Gtk.ListBoxRow used to choose from a list of items.

combo-row

The AdwComboRow widget allows the user to choose from a list of valid choices. The row displays the selected choice. When activated, the row displays a popover which allows the user to make a new choice.

Example of an AdwComboRow UI definition:

<object class="AdwComboRow">
<property name="title" translatable="yes">Combo Row</property>
<property name="model">
<object class="GtkStringList">
<items>
<item translatable="yes">Foo</item>
<item translatable="yes">Bar</item>
<item translatable="yes">Baz</item>
</items>
</object>
</property>
</object>

The property@ComboRow:selected and property@ComboRow:selected-item properties can be used to keep track of the selected item and react to their changes.

AdwComboRow mirrors class@Gtk.DropDown, see that widget for details.

AdwComboRow is property@Gtk.ListBoxRow:activatable if a model is set.

CSS nodes

AdwComboRow has a main CSS node with name row and the .combo style class.

Its popover has the node named popover with the .menu style class, it contains a class@Gtk.ScrolledWindow, which in turn contains a class@Gtk.ListView, both are accessible via their regular nodes.

Accessibility

AdwComboRow uses the GTK_ACCESSIBLE_ROLE_COMBO_BOX role.

Constructors

Link copied to clipboard
constructor()

Creates a new AdwComboRow.

constructor(pointer: <Error class: unknown class><<Error class: unknown class>>)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
open var activatableWidget: <Error class: unknown class>?

The widget to activate when the row is activated.

Link copied to clipboard
val adwActionRowPointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
val adwComboRowPointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
val adwPreferencesRowPointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard

Whether to show a search entry in the popup.

Link copied to clipboard
open var expression: <Error class: unknown class>?

An expression used to obtain strings from items.

Link copied to clipboard
open var factory: <Error class: unknown class>?

Factory for populating list items.

Link copied to clipboard
open override val gtkAccessiblePointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
open override val gtkActionablePointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
open override val gtkBuildablePointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
open override val gtkConstraintTargetPointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
open var headerFactory: <Error class: unknown class>?

The factory for creating header widgets for the popup.

Link copied to clipboard
open var iconName: String?

The icon name for this row.

Link copied to clipboard
open var listFactory: <Error class: unknown class>?

The factory for populating list items in the popup.

Link copied to clipboard
open var model: <Error class: unknown class>?

The model that provides the displayed items.

Link copied to clipboard
open var searchMatchMode: <Error class: unknown class>

The match mode for the search filter.

Link copied to clipboard
open var selected: <Error class: unknown class>

The position of the selected item.

Link copied to clipboard
open val selectedItem: <Error class: unknown class>?

The selected item.

Link copied to clipboard
open var subtitleLines: Int

The number of lines at the end of which the subtitle label will be ellipsized.

Link copied to clipboard

Whether the user can copy the subtitle from the label.

Link copied to clipboard
open var title: String

The title of the preference represented by this row.

Link copied to clipboard
open var titleLines: Int

The number of lines at the end of which the title label will be ellipsized.

Link copied to clipboard

Whether the user can copy the title from the label.

Link copied to clipboard
open var useMarkup: Boolean

Whether to use Pango markup for the title label.

Link copied to clipboard

Whether to use the current value as the subtitle.

Link copied to clipboard

Whether an embedded underline in the title indicates a mnemonic.

Functions

Link copied to clipboard
open fun activate_()

Activates @self.

Link copied to clipboard
open fun addPrefix(widget: <Error class: unknown class>)

Adds a prefix widget to @self.

Link copied to clipboard
open fun addSuffix(widget: <Error class: unknown class>)

Adds a suffix widget to @self.

Link copied to clipboard
fun connectActivated(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: () -> Unit): <Error class: unknown class>

This signal is emitted after the row has been activated.

Link copied to clipboard
open fun getActivatableWidget(): <Error class: unknown class>?

Gets the widget activated when @self is activated.

Link copied to clipboard

Gets whether search is enabled.

Link copied to clipboard
open fun getExpression(): <Error class: unknown class>?

Gets the expression used to obtain strings from items.

Link copied to clipboard
open fun getFactory(): <Error class: unknown class>?

Gets the factory for populating list items.

Link copied to clipboard
open fun getHeaderFactory(): <Error class: unknown class>?

Gets the factory that's currently used to create header widgets for the popup.

Link copied to clipboard
open fun getIconName(): String?

Gets the icon name for @self.

Link copied to clipboard
open fun getListFactory(): <Error class: unknown class>?

Gets the factory for populating list items in the popup.

Link copied to clipboard
open fun getModel(): <Error class: unknown class>?

Gets the model that provides the displayed items.

Link copied to clipboard
open fun getSearchMatchMode(): <Error class: unknown class>

Returns the match mode that the search filter is using.

Link copied to clipboard
open fun getSelected(): <Error class: unknown class>

Gets the position of the selected item.

Link copied to clipboard
open fun getSelectedItem(): <Error class: unknown class>?

Gets the selected item.

Link copied to clipboard
open fun getSubtitle(): String?

Gets the subtitle for @self.

Link copied to clipboard
open fun getSubtitleLines(): Int

Gets the number of lines at the end of which the subtitle label will be ellipsized.

Link copied to clipboard

Gets whether the user can copy the subtitle from the label

Link copied to clipboard
open fun getTitle(): String

Gets the title of the preference represented by @self.

Link copied to clipboard
open fun getTitleLines(): Int

Gets the number of lines at the end of which the title label will be ellipsized.

Link copied to clipboard

Gets whether the user can copy the title from the label

Link copied to clipboard
open fun getUseMarkup(): Boolean

Gets whether to use Pango markup for the title label.

Link copied to clipboard

Gets whether to use the current value as the subtitle.

Link copied to clipboard

Gets whether an embedded underline in the title indicates a mnemonic.

Link copied to clipboard
open fun remove(widget: <Error class: unknown class>)

Removes a child from @self.

Link copied to clipboard
open fun setActivatableWidget(widget: <Error class: unknown class>? = null)

Sets the widget to activate when @self is activated.

Link copied to clipboard
open fun setEnableSearch(enableSearch: Boolean)

Sets whether to enable search.

Link copied to clipboard
open fun setExpression(expression: <Error class: unknown class>? = null)

Sets the expression used to obtain strings from items.

Link copied to clipboard
open fun setFactory(factory: <Error class: unknown class>? = null)

Sets the factory for populating list items.

Link copied to clipboard
open fun setHeaderFactory(factory: <Error class: unknown class>? = null)

Sets the factory to use for creating header widgets for the popup.

Link copied to clipboard
open fun setIconName(iconName: String? = null)

Sets the icon name for @self.

Link copied to clipboard
open fun setListFactory(factory: <Error class: unknown class>? = null)

Sets the factory for populating list items in the popup.

Link copied to clipboard
open fun setModel(model: <Error class: unknown class>? = null)

Sets the model that provides the displayed items.

Link copied to clipboard
open fun setSearchMatchMode(searchMatchMode: <Error class: unknown class>)

Sets the match mode for the search filter.

Link copied to clipboard
open fun setSelected(position: <Error class: unknown class>)

Selects the item at the given position.

Link copied to clipboard
open fun setSubtitle(subtitle: String)

Sets the subtitle for @self.

Link copied to clipboard
open fun setSubtitleLines(subtitleLines: Int)

Sets the number of lines at the end of which the subtitle label will be ellipsized.

Link copied to clipboard
open fun setSubtitleSelectable(subtitleSelectable: Boolean)

Sets whether the user can copy the subtitle from the label

Link copied to clipboard
open fun setTitle(title: String)

Sets the title of the preference represented by @self.

Link copied to clipboard
open fun setTitleLines(titleLines: Int)

Sets the number of lines at the end of which the title label will be ellipsized.

Link copied to clipboard
open fun setTitleSelectable(titleSelectable: Boolean)

Sets whether the user can copy the title from the label

Link copied to clipboard
open fun setUseMarkup(useMarkup: Boolean)

Sets whether to use Pango markup for the title label.

Link copied to clipboard
open fun setUseSubtitle(useSubtitle: Boolean)

Sets whether to use the current value as the subtitle.

Link copied to clipboard
open fun setUseUnderline(useUnderline: Boolean)

Sets whether an embedded underline in the title indicates a mnemonic.