Class EntryRow.Builder<B extends EntryRow.Builder<B>>
- Type Parameters:
B
- the type of the Builder that is returned
- All Implemented Interfaces:
BuilderInterface
,Accessible.Builder<B>
,Actionable.Builder<B>
,Editable.Builder<B>
- Direct Known Subclasses:
PasswordEntryRow.Builder
- Enclosing class:
EntryRow
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Finish building theEntryRow
object.onApply
(EntryRow.ApplyCallback handler) Emitted when the apply button is pressed.Emitted when the embedded entry is activated.setActivatesDefault
(boolean activatesDefault) Whether activating the embedded entry can activate the default widget.setAttributes
(AttrList attributes) A list of Pango attributes to apply to the text of the embedded entry.setEnableEmojiCompletion
(boolean enableEmojiCompletion) Whether to suggest emoji replacements on the entry row.setInputHints
(Set<InputHints> inputHints) Additional input hints for the entry row.setInputHints
(InputHints... inputHints) Additional input hints for the entry row.setInputPurpose
(InputPurpose inputPurpose) The input purpose of the entry row.setMaxLength
(int maxLength) Maximum number of characters for the entry.setShowApplyButton
(boolean showApplyButton) Whether to show the apply button.Methods inherited from class org.gnome.adw.PreferencesRow.Builder
setTitle, setTitleSelectable, setUseMarkup, setUseUnderline
Methods inherited from class org.gnome.gtk.ListBoxRow.Builder
onActivate, setActivatable, setChild, setSelectable
Methods 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, setMarginBottom, setMarginEnd, setMarginStart, setMarginTop, setName, setOpacity, setOverflow, setReceivesDefault, setSensitive, setTooltipMarkup, setTooltipText, setValign, setVexpand, setVexpandSet, setVisible, setWidthRequest
Methods inherited from class org.gnome.gobject.GObject.Builder
onNotify
Methods inherited from class io.github.jwharm.javagi.gobject.Builder
addBuilderProperty, connect, connect, connectSignals, getArena, getNames, getValues
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.gnome.gtk.Accessible.Builder
setAccessibleRole
Methods inherited from interface org.gnome.gtk.Actionable.Builder
setActionName, setActionTarget
Methods inherited from interface io.github.jwharm.javagi.gobject.BuilderInterface
addBuilderProperty, connect, connect, getArena
Methods inherited from interface org.gnome.gtk.Editable.Builder
setEditable, setEnableUndo, setMaxWidthChars, setText, setWidthChars, setXalign
-
Constructor Details
-
Builder
protected Builder()Default constructor for aBuilder
object.
-
-
Method Details
-
build
Finish building theEntryRow
object. 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 toEntryRow
.- Overrides:
build
in classPreferencesRow.Builder<B extends EntryRow.Builder<B>>
- Returns:
- a new instance of
EntryRow
with the properties that were set in the Builder object.
-
setActivatesDefault
Whether activating the embedded entry can activate the default widget.- Parameters:
activatesDefault
- the value for theactivates-default
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-
setAttributes
A list of Pango attributes to apply to the text of the embedded entry.The
Pango.Attribute
'sstart_index
andend_index
must refer to theEntryBuffer
text, i.e. without the preedit string.- Parameters:
attributes
- the value for theattributes
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-
setEnableEmojiCompletion
Whether to suggest emoji replacements on the entry row.Emoji replacement is done with :-delimited names, like
:heart:
.- Parameters:
enableEmojiCompletion
- the value for theenable-emoji-completion
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-
setInputHints
Additional input hints for the entry row.Input hints allow input methods to fine-tune their behavior.
See also:
Adw.EntryRow:input-purpose
- Parameters:
inputHints
- the value for theinput-hints
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-
setInputPurpose
The input purpose of the entry row.The input purpose can be used by input methods to adjust their behavior.
- Parameters:
inputPurpose
- the value for theinput-purpose
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-
setMaxLength
Maximum number of characters for the entry.- Parameters:
maxLength
- the value for themax-length
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-
setShowApplyButton
Whether to show the apply button.When set to
TRUE
, typing text in the entry will reveal an apply button. Clicking it or pressing theEnter
key will hide the button and emit theEntryRow::apply
signal.This is useful if changing the entry contents can trigger an expensive operation, e.g. network activity, to avoid triggering it after typing every character.
- Parameters:
showApplyButton
- the value for theshow-apply-button
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-
setInputHints
Additional input hints for the entry row.Input hints allow input methods to fine-tune their behavior.
See also:
Adw.EntryRow:input-purpose
- Parameters:
inputHints
- the value for theinput-hints
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-
onApply
Emitted when the apply button is pressed.See
EntryRow:show-apply-button
.- Parameters:
handler
- the signal handler- Returns:
- the
Builder
instance is returned, to allow method chaining - See Also:
-
onEntryActivated
Emitted when the embedded entry is activated.- Parameters:
handler
- the signal handler- Returns:
- the
Builder
instance is returned, to allow method chaining - See Also:
-