Gtk.Entry¶
Example¶
- Subclasses:
None
Methods¶
- Inherited:
Gtk.Widget (181), GObject.Object (37), Gtk.Accessible (15), Gtk.Buildable (1), Gtk.CellEditable (3), Gtk.Editable (27)
- Structs:
Virtual Methods¶
- Inherited:
Gtk.Widget (25), GObject.Object (7), Gtk.Accessible (6), Gtk.Buildable (9), Gtk.CellEditable (3), Gtk.Editable (9)
|
Properties¶
Name |
Type |
Flags |
Short Description |
---|---|---|---|
r/w/en |
|||
r/w/en |
|||
r/w/c/en |
|||
d/r/w/en |
|
||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r/w/en |
|||
r |
|||
r/w/en |
|||
r/w/en |
Signals¶
Name |
Short Description |
---|---|
Emitted when the entry is activated. |
|
Emitted when an activatable icon is clicked. |
|
Emitted on the button release from a mouse click over an activatable icon. |
Fields¶
Name |
Type |
Access |
Description |
---|---|---|---|
parent_instance |
r |
Class Details¶
- class Gtk.Entry(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
GtkEntry
is a single line text entry widget.An example
Gtk.Entry
A fairly large set of key bindings are supported by default. If the entered text is longer than the allocation of the widget, the widget will scroll so that the cursor position is visible.
When using an entry for passwords and other sensitive information, it can be put into “password mode” using [method`Gtk`.Entry.set_visibility]. In this mode, entered text is displayed using a “invisible” character. By default, GTK picks the best invisible character that is available in the current font, but it can be changed with [method`Gtk`.Entry.set_invisible_char].
GtkEntry
has the ability to display progress or activity information behind the text. To make an entry display such information, use [method`Gtk`.Entry.set_progress_fraction] or [method`Gtk`.Entry.set_progress_pulse_step].Additionally,
GtkEntry
can show icons at either side of the entry. These icons can be activatable by clicking, can be set up as drag source and can have tooltips. To add an icon, use [method`Gtk`.Entry.set_icon_from_gicon] or one of the various other functions that set an icon from an icon name or a paintable. To trigger an action when the user clicks an icon, connect to the [signal`Gtk`.Entry::icon-press] signal. To allow DND operations from an icon, use [method`Gtk`.Entry.set_icon_drag_source]. To set a tooltip on an icon, use [method`Gtk`.Entry.set_icon_tooltip_text] or the corresponding function for markup.Note that functionality or information that is only available by clicking on an icon in an entry may not be accessible at all to users which are not able to use a mouse or other pointing device. It is therefore recommended that any such functionality should also be available by other means, e.g. via the context menu of the entry.
- CSS nodes
`` entry[.flat][.warning][.error] ├── text[.readonly] ├── image.left ├── image.right ╰── [progress[.pulse]] ``
GtkEntry
has a main node with the name entry. Depending on the properties of the entry, the style classes .read-only and .flat may appear. The style classes .warning and .error may also be used with entries.When the entry shows icons, it adds subnodes with the name image and the style class .left or .right, depending on where the icon appears.
When the entry shows progress, it adds a subnode with the name progress. The node has the style class .pulse when the shown progress is pulsing.
For all the subnodes added to the text node in various situations, see [class`Gtk`.Text].
The
GtkEntry
implementation of theGtkBuildable
interface supports a custom<attributes>
element, which supports any number of<attribute>
elements. The<attribute>
element has attributes named “name“, “value“, “start“ and “end“ and allows you to specifyPangoAttribute
values for this label.An example of a UI definition fragment specifying Pango attributes: ``xml <object class=”GtkEntry”>
- <attributes>
<attribute name=”weight” value=”PANGO_WEIGHT_BOLD”/> <attribute name=”background” value=”red” start=”5” end=”10”/>
</attributes>
</object> ``
The start and end attributes specify the range of characters to which the Pango attribute applies. If start and end are not specified, the attribute is applied to the whole text. Note that specifying ranges does not make much sense with translatable attributes. Use markup embedded in the translatable content instead.
- Accessibility
GtkEntry
uses theGtk.AccessibleRole.TEXT_BOX
role.- classmethod new_with_buffer(buffer)[source]¶
- Parameters:
buffer (
Gtk.EntryBuffer
) – The buffer to use for the newGtkEntry
.- Returns:
a new
GtkEntry
- Return type:
Creates a new entry with the specified text buffer.
- get_activates_default()[source]¶
-
Retrieves the value set by
Gtk.Entry.set_activates_default
().
- get_alignment()[source]¶
- Returns:
the alignment
- Return type:
Gets the value set by
Gtk.Entry.set_alignment
().See also: [property`Gtk`.Editable:xalign]
- get_attributes()[source]¶
- Returns:
the attribute list
- Return type:
Gets the attribute list of the
GtkEntry
.See [method`Gtk`.Entry.set_attributes].
- get_buffer()[source]¶
- Returns:
A
GtkEntryBuffer
object.- Return type:
Get the
GtkEntryBuffer
object which holds the text for this widget.
- get_completion()[source]¶
- Returns:
The auxiliary completion object currently in use by self
- Return type:
Returns the auxiliary completion object currently in use by self.
Deprecated since version 4.10:
Gtk.EntryCompletion
will be removed in GTK 5.
- get_current_icon_drag_source()[source]¶
- Returns:
index of the icon which is the source of the current DND operation, or -1.
- Return type:
Returns the index of the icon which is the source of the current DND operation, or -1.
- Returns:
the menu model
- Return type:
Gets the menu model set with
Gtk.Entry.set_extra_menu
().
- get_has_frame()[source]¶
- Returns:
whether the entry has a beveled frame
- Return type:
Gets the value set by
Gtk.Entry.set_has_frame
().
- get_icon_activatable(icon_pos)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – Icon position- Returns:
True
if the icon is activatable.- Return type:
Returns whether the icon is activatable.
- get_icon_area(icon_pos)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – Icon position- Returns:
Return location for the icon’s area
- Return type:
icon_area:
Gdk.Rectangle
Gets the area where entry’s icon at icon_pos is drawn.
This function is useful when drawing something to the entry in a draw callback.
If the entry is not realized or has no icon at the given position, icon_area is filled with zeros. Otherwise, icon_area will be filled with the icon’s allocation, relative to self's allocation.
- get_icon_at_pos(x, y)[source]¶
- Parameters:
- Returns:
the index of the icon at the given position, or -1
- Return type:
Finds the icon at the given position and return its index.
The position’s coordinates are relative to the self’s top left corner. If x, y doesn’t lie inside an icon, -1 is returned. This function is intended for use in a [signal`Gtk`.Widget::query-tooltip] signal handler.
- get_icon_gicon(icon_pos)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – Icon position- Returns:
A
GIcon
- Return type:
Retrieves the
GIcon
used for the icon.None
will be returned if there is no icon or if the icon was set by some other method (e.g., byGdkPaintable
or icon name).
- get_icon_name(icon_pos)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – Icon position- Returns:
An icon name
- Return type:
Retrieves the icon name used for the icon.
None
is returned if there is no icon or if the icon was set by some other method (e.g., byGdkPaintable
or gicon).
- get_icon_paintable(icon_pos)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – Icon position- Returns:
A
GdkPaintable
if no icon is set for this position or the icon set is not aGdkPaintable
.- Return type:
Retrieves the
GdkPaintable
used for the icon.If no
GdkPaintable
was used for the icon,None
is returned.
- get_icon_sensitive(icon_pos)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – Icon position- Returns:
True
if the icon is sensitive.- Return type:
Returns whether the icon appears sensitive or insensitive.
- get_icon_storage_type(icon_pos)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – Icon position- Returns:
image representation being used
- Return type:
Gets the type of representation being used by the icon to store image data.
If the icon has no image data, the return value will be
Gtk.ImageType.EMPTY
.
- get_icon_tooltip_markup(icon_pos)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – the icon position- Returns:
the tooltip text
- Return type:
Gets the contents of the tooltip on the icon at the specified position in self.
- get_icon_tooltip_text(icon_pos)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – the icon position- Returns:
the tooltip text
- Return type:
Gets the contents of the tooltip on the icon at the specified position in self.
- get_input_hints()[source]¶
- Returns:
the input hints
- Return type:
Gets the input hints of this
GtkEntry
.
- get_input_purpose()[source]¶
- Returns:
the input purpose
- Return type:
Gets the input purpose of the
GtkEntry
.
- get_invisible_char()[source]¶
- Returns:
the current invisible
str
, or 0, if the entry does not show invisible text at all.- Return type:
Retrieves the character displayed in place of the actual text in “password mode”.
- get_max_length()[source]¶
- Returns:
the maximum allowed number of characters in
GtkEntry
, or 0 if there is no maximum.- Return type:
Retrieves the maximum allowed length of the text in self.
See [method`Gtk`.Entry.set_max_length].
- get_overwrite_mode()[source]¶
- Returns:
whether the text is overwritten when typing.
- Return type:
Gets whether the
GtkEntry
is in overwrite mode.
- get_placeholder_text()[source]¶
- Returns:
a pointer to the placeholder text as a string. This string points to internally allocated storage in the widget and must not be freed, modified or stored. If no placeholder text has been set,
None
will be returned.- Return type:
Retrieves the text that will be displayed when self is empty and unfocused
- get_progress_fraction()[source]¶
- Returns:
a fraction from 0.0 to 1.0
- Return type:
Returns the current fraction of the task that’s been completed.
See [method`Gtk`.Entry.set_progress_fraction].
- get_progress_pulse_step()[source]¶
- Returns:
a fraction from 0.0 to 1.0
- Return type:
Retrieves the pulse step set with
Gtk.Entry.set_progress_pulse_step
().
- get_tabs()[source]¶
- Returns:
the tabstops
- Return type:
Gets the tabstops of the
GtkEntry
.See [method`Gtk`.Entry.set_tabs].
- get_text_length()[source]¶
- Returns:
the current number of characters in
GtkEntry
, or 0 if there are none.- Return type:
Retrieves the current length of the text in self.
This is equivalent to getting self's
GtkEntryBuffer
and calling [method`Gtk`.EntryBuffer.get_length] on it.
- get_visibility()[source]¶
-
Retrieves whether the text in self is visible.
See [method`Gtk`.Entry.set_visibility].
- grab_focus_without_selecting()[source]¶
-
Causes self to have keyboard focus.
It behaves like [method`Gtk`.Widget.grab_focus], except that it doesn’t select the contents of the entry. You only want to call this on some special entries which the user usually doesn’t want to replace all text in, such as search-as-you-type entries.
- progress_pulse()[source]¶
Indicates that some progress is made, but you don’t know how much.
Causes the entry’s progress indicator to enter “activity mode”, where a block bounces back and forth. Each call to
Gtk.Entry.progress_pulse
() causes the block to move by a little bit (the amount of movement per pulse is determined by [method`Gtk`.Entry.set_progress_pulse_step]).
- reset_im_context()[source]¶
Reset the input method context of the entry if needed.
This can be necessary in the case where modifying the buffer would confuse on-going input method behavior.
- set_activates_default(setting)[source]¶
-
Sets whether pressing Enter in the self will activate the default widget for the window containing the entry.
This usually means that the dialog containing the entry will be closed, since the default widget is usually one of the dialog buttons.
- set_alignment(xalign)[source]¶
- Parameters:
xalign (
float
) – The horizontal alignment, from 0 (left) to 1 (right). Reversed for RTL layouts
Sets the alignment for the contents of the entry.
This controls the horizontal positioning of the contents when the displayed text is shorter than the width of the entry.
See also: [property`Gtk`.Editable:xalign]
- set_attributes(attrs)[source]¶
- Parameters:
attrs (
Pango.AttrList
) – aPangoAttrList
Sets a
PangoAttrList
.The attributes in the list are applied to the entry text.
Since the attributes will be applied to text that changes as the user types, it makes most sense to use attributes with unlimited extent.
- set_buffer(buffer)[source]¶
- Parameters:
buffer (
Gtk.EntryBuffer
) – aGtkEntryBuffer
Set the
GtkEntryBuffer
object which holds the text for this widget.
- set_completion(completion)[source]¶
- Parameters:
completion (
Gtk.EntryCompletion
orNone
) – TheGtkEntryCompletion
Sets completion to be the auxiliary completion object to use with self.
All further configuration of the completion mechanism is done on completion using the
GtkEntryCompletion
API. Completion is disabled if completion is set toNone
.Deprecated since version 4.10:
Gtk.EntryCompletion
will be removed in GTK 5.
- Parameters:
model (
Gio.MenuModel
orNone
) – aGMenuModel
Sets a menu model to add when constructing the context menu for self.
- set_has_frame(setting)[source]¶
- Parameters:
setting (
bool
) – new value
Sets whether the entry has a beveled frame around it.
- set_icon_activatable(icon_pos, activatable)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – Icon position
Sets whether the icon is activatable.
- set_icon_drag_source(icon_pos, provider, actions)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – icon positionprovider (
Gdk.ContentProvider
) – aGdkContentProvider
actions (
Gdk.DragAction
) – a bitmask of the allowed drag actions
Sets up the icon at the given position as drag source.
This makes it so that GTK will start a drag operation when the user clicks and drags the icon.
- set_icon_from_gicon(icon_pos, icon)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – The position at which to set the icon
Sets the icon shown in the entry at the specified position from the current icon theme.
If the icon isn’t known, a “broken image” icon will be displayed instead.
If icon is
None
, no icon will be shown in the specified position.
- set_icon_from_icon_name(icon_pos, icon_name)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – The position at which to set the icon
Sets the icon shown in the entry at the specified position from the current icon theme.
If the icon name isn’t known, a “broken image” icon will be displayed instead.
If icon_name is
None
, no icon will be shown in the specified position.
- set_icon_from_paintable(icon_pos, paintable)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – Icon positionpaintable (
Gdk.Paintable
orNone
) – AGdkPaintable
Sets the icon shown in the specified position using a
GdkPaintable
.If paintable is
None
, no icon will be shown in the specified position.
- set_icon_sensitive(icon_pos, sensitive)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – Icon positionsensitive (
bool
) – Specifies whether the icon should appear sensitive or insensitive
Sets the sensitivity for the specified icon.
- set_icon_tooltip_markup(icon_pos, tooltip)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – the icon positiontooltip (
str
orNone
) – the contents of the tooltip for the icon
Sets tooltip as the contents of the tooltip for the icon at the specified position.
tooltip is assumed to be marked up with Pango Markup.
Use
None
for tooltip to remove an existing tooltip.See also [method`Gtk`.Widget.set_tooltip_markup] and [method`Gtk`.Entry.set_icon_tooltip_text].
- set_icon_tooltip_text(icon_pos, tooltip)[source]¶
- Parameters:
icon_pos (
Gtk.EntryIconPosition
) – the icon positiontooltip (
str
orNone
) – the contents of the tooltip for the icon
Sets tooltip as the contents of the tooltip for the icon at the specified position.
Use
None
for tooltip to remove an existing tooltip.See also [method`Gtk`.Widget.set_tooltip_text] and [method`Gtk`.Entry.set_icon_tooltip_markup].
If you unset the widget tooltip via [method`Gtk`.Widget.set_tooltip_text] or [method`Gtk`.Widget.set_tooltip_markup], this sets [property`Gtk`.Widget:has-tooltip] to
False
, which suppresses icon tooltips too. You can resolve this by then calling [method`Gtk`.Widget.set_has_tooltip] to set [property`Gtk`.Widget:has-tooltip] back toTrue
, or setting at least one non-empty tooltip on any icon achieves the same result.
- set_input_hints(hints)[source]¶
- Parameters:
hints (
Gtk.InputHints
) – the hints
Set additional hints which allow input methods to fine-tune their behavior.
- set_input_purpose(purpose)[source]¶
- Parameters:
purpose (
Gtk.InputPurpose
) – the purpose
Sets the input purpose which can be used by input methods to adjust their behavior.
- set_invisible_char(ch)[source]¶
- Parameters:
ch (
str
) – a Unicode character
Sets the character to use in place of the actual text in “password mode”.
See [method`Gtk`.Entry.set_visibility] for how to enable “password mode”.
By default, GTK picks the best invisible
str
available in the current font. If you set the invisiblestr
to 0, then the user will get no feedback at all; there will be no text on the screen as they type.
- set_max_length(max)[source]¶
- Parameters:
max (
int
) – the maximum length of the entry, or 0 for no maximum. (other than the maximum length of entries.) The value passed in will be clamped to the range 0-65536.
Sets the maximum allowed length of the contents of the widget.
If the current contents are longer than the given length, then they will be truncated to fit. The length is in characters.
This is equivalent to getting self's
GtkEntryBuffer
and calling [method`Gtk`.EntryBuffer.set_max_length] on it.
- set_overwrite_mode(overwrite)[source]¶
- Parameters:
overwrite (
bool
) – new value
Sets whether the text is overwritten when typing in the
GtkEntry
.
- set_placeholder_text(text)[source]¶
-
Sets text to be displayed in self when it is empty.
This can be used to give a visual hint of the expected contents of the
GtkEntry
.
- set_progress_fraction(fraction)[source]¶
- Parameters:
fraction (
float
) – fraction of the task that’s been completed
Causes the entry’s progress indicator to “fill in” the given fraction of the bar.
The fraction should be between 0.0 and 1.0, inclusive.
- set_progress_pulse_step(fraction)[source]¶
- Parameters:
fraction (
float
) – fraction between 0.0 and 1.0
Sets the fraction of total entry width to move the progress bouncing block for each pulse.
Use [method`Gtk`.Entry.progress_pulse] to pulse the progress.
- set_tabs(tabs)[source]¶
- Parameters:
tabs (
Pango.TabArray
orNone
) – aPangoTabArray
Sets a
PangoTabArray
.The tabstops in the array are applied to the entry text.
- set_visibility(visible)[source]¶
-
Sets whether the contents of the entry are visible or not.
When visibility is set to
False
, characters are displayed as the invisiblestr
, and will also appear that way when the text in the entry widget is copied elsewhere.By default, GTK picks the best invisible character available in the current font, but it can be changed with [method`Gtk`.Entry.set_invisible_char].
Note that you probably want to set [property`Gtk`.Entry:input-purpose] to
Gtk.InputPurpose.PASSWORD
orGtk.InputPurpose.PIN
to inform input methods about the purpose of this entry, in addition to setting visibility toFalse
.
- unset_invisible_char()[source]¶
Unsets the invisible
str
, so that the default invisiblestr
is used again. See [method`Gtk`.Entry.set_invisible_char].
- do_activate() virtual¶
Class handler for the
GtkEntry::activate
signal. The default implementation activates the gtk.activate-default action.
Signal Details¶
- Gtk.Entry.signals.activate(entry)¶
- Signal Name:
activate
- Flags:
- Parameters:
entry (
Gtk.Entry
) – The object which received the signal
Emitted when the entry is activated.
The keybindings for this signal are all forms of the Enter key.
- Gtk.Entry.signals.icon_press(entry, icon_pos)¶
- Signal Name:
icon-press
- Flags:
- Parameters:
entry (
Gtk.Entry
) – The object which received the signalicon_pos (
Gtk.EntryIconPosition
) – The position of the clicked icon
Emitted when an activatable icon is clicked.
- Gtk.Entry.signals.icon_release(entry, icon_pos)¶
- Signal Name:
icon-release
- Flags:
- Parameters:
entry (
Gtk.Entry
) – The object which received the signalicon_pos (
Gtk.EntryIconPosition
) – The position of the clicked icon
Emitted on the button release from a mouse click over an activatable icon.
Property Details¶
- Gtk.Entry.props.activates_default¶
- Name:
activates-default
- Type:
- Default Value:
- Flags:
Whether to activate the default widget when Enter is pressed.
- Gtk.Entry.props.attributes¶
- Name:
attributes
- Type:
- Default Value:
- Flags:
A list of Pango attributes to apply to the text of the entry.
This is mainly useful to change the size or weight of the text.
The
PangoAttribute
’s start_index and end_index must refer to the [class`Gtk`.EntryBuffer] text, i.e. without the preedit string.
- Gtk.Entry.props.buffer¶
- Name:
buffer
- Type:
- Default Value:
- Flags:
The buffer object which actually stores the text.
- Gtk.Entry.props.completion¶
- Name:
completion
- Type:
- Default Value:
- Flags:
The auxiliary completion object to use with the entry.
Deprecated since version 4.10:
Gtk.EntryCompletion
will be removed in GTK 5.
- Gtk.Entry.props.enable_emoji_completion¶
- Name:
enable-emoji-completion
- Type:
- Default Value:
- Flags:
Whether to suggest Emoji replacements for
:-delimited
names like:heart:
.
- Name:
extra-menu
- Type:
- Default Value:
- Flags:
A menu model whose contents will be appended to the context menu.
- Gtk.Entry.props.has_frame¶
- Name:
has-frame
- Type:
- Default Value:
- Flags:
Whether the entry should draw a frame.
- Gtk.Entry.props.im_module¶
- Name:
im-module
- Type:
- Default Value:
- Flags:
Which IM (input method) module should be used for this entry.
See [class`Gtk`.IMContext].
Setting this to a non-
None
value overrides the system-wide IM module setting. See theGtk.Settings
[property`Gtk`.Settings:gtk-im-module] property.
- Gtk.Entry.props.input_hints¶
- Name:
input-hints
- Type:
- Default Value:
- Flags:
Additional hints that allow input methods to fine-tune their behavior.
Also see [property`Gtk`.Entry:input-purpose]
- Gtk.Entry.props.input_purpose¶
- Name:
input-purpose
- Type:
- Default Value:
- Flags:
The purpose of this text field.
This property can be used by on-screen keyboards and other input methods to adjust their behaviour.
Note that setting the purpose to
Gtk.InputPurpose.PASSWORD
orGtk.InputPurpose.PIN
is independent from setting [property`Gtk`.Entry:visibility].
- Gtk.Entry.props.invisible_char¶
- Name:
invisible-char
- Type:
- Default Value:
42
- Flags:
The character to use when masking entry contents (“password mode”).
- Gtk.Entry.props.max_length¶
- Name:
max-length
- Type:
- Default Value:
0
- Flags:
Maximum number of characters for this entry.
- Gtk.Entry.props.overwrite_mode¶
- Name:
overwrite-mode
- Type:
- Default Value:
- Flags:
If text is overwritten when typing in the
GtkEntry
.
- Gtk.Entry.props.placeholder_text¶
- Name:
placeholder-text
- Type:
- Default Value:
- Flags:
The text that will be displayed in the
GtkEntry
when it is empty and unfocused.
- Gtk.Entry.props.primary_icon_activatable¶
- Name:
primary-icon-activatable
- Type:
- Default Value:
- Flags:
Whether the primary icon is activatable.
GTK emits the [signal`Gtk`.Entry::icon-press] and [signal`Gtk`.Entry::icon-release] signals only on sensitive, activatable icons.
Sensitive, but non-activatable icons can be used for purely informational purposes.
- Gtk.Entry.props.primary_icon_gicon¶
- Name:
primary-icon-gicon
- Type:
- Default Value:
- Flags:
The
GIcon
to use for the primary icon for the entry.
- Gtk.Entry.props.primary_icon_name¶
- Name:
primary-icon-name
- Type:
- Default Value:
- Flags:
The icon name to use for the primary icon for the entry.
- Gtk.Entry.props.primary_icon_paintable¶
- Name:
primary-icon-paintable
- Type:
- Default Value:
- Flags:
A
GdkPaintable
to use as the primary icon for the entry.
- Gtk.Entry.props.primary_icon_sensitive¶
- Name:
primary-icon-sensitive
- Type:
- Default Value:
- Flags:
Whether the primary icon is sensitive.
An insensitive icon appears grayed out. GTK does not emit the [signal`Gtk`.Entry::icon-press] and [signal`Gtk`.Entry::icon-release] signals and does not allow DND from insensitive icons.
An icon should be set insensitive if the action that would trigger when clicked is currently not available.
- Gtk.Entry.props.primary_icon_storage_type¶
- Name:
primary-icon-storage-type
- Type:
- Default Value:
- Flags:
The representation which is used for the primary icon of the entry.
- Gtk.Entry.props.primary_icon_tooltip_markup¶
- Name:
primary-icon-tooltip-markup
- Type:
- Default Value:
- Flags:
The contents of the tooltip on the primary icon, with markup.
Also see [method`Gtk`.Entry.set_icon_tooltip_markup].
- Gtk.Entry.props.primary_icon_tooltip_text¶
- Name:
primary-icon-tooltip-text
- Type:
- Default Value:
- Flags:
The contents of the tooltip on the primary icon.
Also see [method`Gtk`.Entry.set_icon_tooltip_text].
- Gtk.Entry.props.progress_fraction¶
- Name:
progress-fraction
- Type:
- Default Value:
0.0
- Flags:
The current fraction of the task that’s been completed.
- Gtk.Entry.props.progress_pulse_step¶
- Name:
progress-pulse-step
- Type:
- Default Value:
0.0
- Flags:
The fraction of total entry width to move the progress bouncing block for each pulse.
See [method`Gtk`.Entry.progress_pulse].
- Gtk.Entry.props.scroll_offset¶
- Name:
scroll-offset
- Type:
- Default Value:
0
- Flags:
Number of pixels of the entry scrolled off the screen to the left.
- Gtk.Entry.props.secondary_icon_activatable¶
- Name:
secondary-icon-activatable
- Type:
- Default Value:
- Flags:
Whether the secondary icon is activatable.
GTK emits the [signal`Gtk`.Entry::icon-press] and [signal`Gtk`.Entry::icon-release] signals only on sensitive, activatable icons.
Sensitive, but non-activatable icons can be used for purely informational purposes.
- Gtk.Entry.props.secondary_icon_gicon¶
- Name:
secondary-icon-gicon
- Type:
- Default Value:
- Flags:
The
GIcon
to use for the secondary icon for the entry.
- Gtk.Entry.props.secondary_icon_name¶
- Name:
secondary-icon-name
- Type:
- Default Value:
- Flags:
The icon name to use for the secondary icon for the entry.
- Gtk.Entry.props.secondary_icon_paintable¶
- Name:
secondary-icon-paintable
- Type:
- Default Value:
- Flags:
A
GdkPaintable
to use as the secondary icon for the entry.
- Gtk.Entry.props.secondary_icon_sensitive¶
- Name:
secondary-icon-sensitive
- Type:
- Default Value:
- Flags:
Whether the secondary icon is sensitive.
An insensitive icon appears grayed out. GTK does not emit the [signal`Gtk`.Entry::icon-press[ and [signal`Gtk`.Entry::icon-release] signals and does not allow DND from insensitive icons.
An icon should be set insensitive if the action that would trigger when clicked is currently not available.
- Gtk.Entry.props.secondary_icon_storage_type¶
- Name:
secondary-icon-storage-type
- Type:
- Default Value:
- Flags:
The representation which is used for the secondary icon of the entry.
- Gtk.Entry.props.secondary_icon_tooltip_markup¶
- Name:
secondary-icon-tooltip-markup
- Type:
- Default Value:
- Flags:
The contents of the tooltip on the secondary icon, with markup.
Also see [method`Gtk`.Entry.set_icon_tooltip_markup].
- Gtk.Entry.props.secondary_icon_tooltip_text¶
- Name:
secondary-icon-tooltip-text
- Type:
- Default Value:
- Flags:
The contents of the tooltip on the secondary icon.
Also see [method`Gtk`.Entry.set_icon_tooltip_text].
- Gtk.Entry.props.show_emoji_icon¶
- Name:
show-emoji-icon
- Type:
- Default Value:
- Flags:
- Gtk.Entry.props.tabs¶
- Name:
tabs
- Type:
- Default Value:
- Flags:
- Gtk.Entry.props.text_length¶
-
The length of the text in the
GtkEntry
.