Package org.gnome.gtk
Class ListBox.Builder<B extends ListBox.Builder<B>>
java.lang.Object
org.javagi.gobject.Builder<B>
org.gnome.gobject.GObject.Builder<B>
org.gnome.gobject.InitiallyUnowned.Builder<B>
org.gnome.gtk.Widget.Builder<B>
org.gnome.gtk.ListBox.Builder<B>
- Type Parameters:
B- the type of the Builder that is returned
- All Implemented Interfaces:
Accessible.Builder<B>,BuilderInterface
- Enclosing class:
ListBox
public static class ListBox.Builder<B extends ListBox.Builder<B>>
extends Widget.Builder<B>
implements Accessible.Builder<B>
Inner class implementing a builder pattern to construct a GObject with
properties.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Finish building theListBoxobject.Emitted when the cursor row is activated.onMoveCursor(ListBox.MoveCursorCallback handler) Emitted when the user initiates a cursor movement.Emitted when a row has been activated by the user.onRowSelected(ListBox.RowSelectedCallback handler) Emitted when a new row is selected, or (with anullrow)when the selection is cleared.onSelectAll(ListBox.SelectAllCallback handler) Emitted to select all children of the box, if the selection mode permits it.Emitted when the set of selected rows changes.Emitted when the cursor row is toggled.onUnselectAll(ListBox.UnselectAllCallback handler) Emitted to unselect all children of the box, if the selection mode permits it.setAcceptUnpairedRelease(boolean acceptUnpairedRelease) Whether to accept unpaired release events.setActivateOnSingleClick(boolean activateOnSingleClick) Determines whether children can be activated with a single click, or require a double-click.setSelectionMode(SelectionMode selectionMode) The selection mode used by the list box.setShowSeparators(boolean showSeparators) Whether to show separators between rows.setTabBehavior(ListTabBehavior tabBehavior) Behavior of theTabkeyMethods inherited from class org.gnome.gtk.Widget.Builder
onDestroy, onDirectionChanged, onHide, onKeynavFailed, onMap, onMnemonicActivate, onMoveFocus, onQueryTooltip, onRealize, onShow, onStateFlagsChanged, onUnmap, onUnrealize, setCanFocus, setCanTarget, setCssClasses, setCssName, setCursor, setFocusable, setFocusOnClick, setHalign, setHasTooltip, setHeightRequest, setHexpand, setHexpandSet, setLayoutManager, setLimitEvents, setMarginBottom, setMarginEnd, setMarginStart, setMarginTop, setName, setOpacity, setOverflow, setReceivesDefault, setSensitive, setTooltipMarkup, setTooltipText, setValign, setVexpand, setVexpandSet, setVisible, setWidthRequestMethods inherited from class org.gnome.gobject.GObject.Builder
onNotifyMethods inherited from class org.javagi.gobject.Builder
addBuilderProperty, connect, connect, connectSignals, getArena, getNames, getValuesMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.gnome.gtk.Accessible.Builder
setAccessibleRoleMethods inherited from interface org.javagi.gobject.BuilderInterface
addBuilderProperty, connect, connect, getArena
-
Constructor Details
-
Builder
protected Builder()Default constructor for aBuilderobject.
-
-
Method Details
-
build
Finish building theListBoxobject. This will callGObject.withProperties(org.gnome.glib.Type, java.lang.String[], org.gnome.gobject.Value[])to create a new GObject instance, which is then cast toListBox.- Overrides:
buildin classWidget.Builder<B extends ListBox.Builder<B>>- Returns:
- a new instance of
ListBoxwith the properties that were set in the Builder object.
-
setAcceptUnpairedRelease
Whether to accept unpaired release events.- Parameters:
acceptUnpairedRelease- the value for theaccept-unpaired-releaseproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-
setActivateOnSingleClick
Determines whether children can be activated with a single click, or require a double-click.- Parameters:
activateOnSingleClick- the value for theactivate-on-single-clickproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-
setSelectionMode
The selection mode used by the list box.- Parameters:
selectionMode- the value for theselection-modeproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-
setShowSeparators
Whether to show separators between rows.- Parameters:
showSeparators- the value for theshow-separatorsproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-
setTabBehavior
Behavior of theTabkey- Parameters:
tabBehavior- the value for thetab-behaviorproperty- Returns:
- the
Builderinstance is returned, to allow method chaining - Since:
- 4.18
-
onActivateCursorRow
Emitted when the cursor row is activated.- Parameters:
handler- the signal handler- Returns:
- the
Builderinstance is returned, to allow method chaining - See Also:
-
onMoveCursor
Emitted when the user initiates a cursor movement.The default bindings for this signal come in two variants, the variant with the Shift modifier extends the selection, the variant without the Shift modifier does not. There are too many key combinations to list them all here.
←,→,↑,↓move by individual childrenHome,Endmove to the ends of the boxPgUp,PgDnmove vertically by pages
- Parameters:
handler- the signal handler- Returns:
- the
Builderinstance is returned, to allow method chaining - See Also:
-
onRowActivated
Emitted when a row has been activated by the user.- Parameters:
handler- the signal handler- Returns:
- the
Builderinstance is returned, to allow method chaining - See Also:
-
onRowSelected
Emitted when a new row is selected, or (with anullrow)when the selection is cleared.When the
boxis usingSelectionMode.MULTIPLE, this signal will not give you the full picture of selection changes, and you should use theGtk.ListBox::selected-rows-changedsignal instead.- Parameters:
handler- the signal handler- Returns:
- the
Builderinstance is returned, to allow method chaining - See Also:
-
onSelectAll
Emitted to select all children of the box, if the selection mode permits it.This is a keybinding signal.
The default binding for this signal is
Ctrl-a.- Parameters:
handler- the signal handler- Returns:
- the
Builderinstance is returned, to allow method chaining - See Also:
-
onSelectedRowsChanged
Emitted when the set of selected rows changes.- Parameters:
handler- the signal handler- Returns:
- the
Builderinstance is returned, to allow method chaining - See Also:
-
onToggleCursorRow
Emitted when the cursor row is toggled.The default bindings for this signal is
Ctrl+␣.- Parameters:
handler- the signal handler- Returns:
- the
Builderinstance is returned, to allow method chaining - See Also:
-
onUnselectAll
Emitted to unselect all children of the box, if the selection mode permits it.This is a keybinding signal.
The default binding for this signal is
Ctrl-Shift-a.- Parameters:
handler- the signal handler- Returns:
- the
Builderinstance is returned, to allow method chaining - See Also:
-