-
public bool get_activates_default ()
-
public float get_alignment ()
-
public weak EntryBuffer get_buffer ()
Get the EntryBuffer object which holds the text for
this widget.
-
public weak EntryCompletion get_completion ()
Returns the auxiliary completion object currently in use by entry.
-
public int get_current_icon_drag_source ()
Returns the index of the icon which is the source of the current DND operation, or -1.
-
public weak Adjustment get_cursor_hadjustment ()
-
public bool get_has_frame ()
-
public bool get_icon_activatable (EntryIconPosition icon_pos)
Returns whether the icon is activatable.
-
public int get_icon_at_pos (int x, int y)
Finds the icon at the given position and return its index. If x, y doesn't
lie inside an icon, -1 is returned. This function is intended for use in a
query_tooltip signal handler.
-
public weak Icon get_icon_gicon (EntryIconPosition icon_pos)
Retrieves the Icon used for the icon, or
null if there is no icon or if the icon was set by some other method (e.g., by stock, pixbuf, or icon name).
-
public unowned string get_icon_name (EntryIconPosition icon_pos)
Retrieves the icon name used for the icon, or null if there is no icon or if the icon was
set by some other method (e.g., by pixbuf, stock or gicon).
-
public weak Pixbuf get_icon_pixbuf (EntryIconPosition icon_pos)
Retrieves the image used for the icon.
-
public bool get_icon_sensitive (EntryIconPosition icon_pos)
Returns whether the icon appears sensitive or insensitive.
-
public unowned string get_icon_stock (EntryIconPosition icon_pos)
Retrieves the stock id used for the icon, or null if there is no icon or if the icon was
set by some other method (e.g., by pixbuf, icon name or gicon).
-
public ImageType get_icon_storage_type (EntryIconPosition icon_pos)
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 EMPTY.
-
public unowned string get_icon_tooltip_markup (EntryIconPosition icon_pos)
Gets the contents of the tooltip on the icon at the specified position in entry.
-
public unowned string get_icon_tooltip_text (EntryIconPosition icon_pos)
Gets the contents of the tooltip on the icon at the specified position in entry.
-
public weak Window get_icon_window (EntryIconPosition icon_pos)
Returns the Window which contains the entry's
icon at icon_pos. This function is useful when drawing something to the entry in an expose-event callback because it
enables the callback to distinguish between the text window and entry's icon windows.
-
public unowned Border get_inner_border ()
-
public unichar get_invisible_char ()
Retrieves the character displayed in place of the real characters for entries with visibility set to
false. See set_invisible_char.
-
public weak Layout get_layout ()
Gets the Layout used to display the entry. The
layout is useful to e.g. convert text positions to pixel positions, in combination with
get_layout_offsets. The returned layout is owned by the entry and
must not be modified or freed by the caller.
-
public void get_layout_offsets (out int x, out int y)
Obtains the position of the Layout used to
render text in the entry, in widget coordinates. Useful if you want to line up the text in an entry with some other text, e.g. when
using the entry to implement editable cells in a sheet widget.
-
public int get_max_length ()
Retrieves the maximum allowed length of the text in entry. See
set_max_length.
-
public bool get_overwrite_mode ()
-
public double get_progress_fraction ()
-
public double get_progress_pulse_step ()
-
public unowned string get_text ()
Retrieves the contents of the entry widget. See also
get_chars.
-
public virtual void get_text_area_size (int x, int y, int width, int height)
-
public uint16 get_text_length ()
Retrieves the current length of the text in entry.
-
public weak Window get_text_window ()
Returns the Window which contains the text.
This function is useful when drawing something to the entry in an expose-event callback because it enables the callback to
distinguish between the text window and entry's icon windows.
-
public bool get_visibility ()
-
public int get_width_chars ()
-
public int layout_index_to_text_index (int layout_index)
Converts from a position in the entry contents (returned by
get_text) to a position in the entry's
Layout (returned by
get_layout, with text retrieved via get_text).
-
public void progress_pulse ()
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
progress_pulse causes the block to move by a little bit (the amount of
movement per pulse is determined by set_progress_pulse_step).
-
public void set_activates_default (bool setting)
If setting is true, pressing Enter in the entry will activate
the default widget for the window containing the entry. This usually means that the dialog box containing the entry will be closed,
since the default widget is usually one of the dialog buttons.
-
public void set_alignment (float xalign)
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.
-
public void set_buffer (EntryBuffer buffer)
Set the EntryBuffer object which holds the text for
this widget.
-
public void set_completion (EntryCompletion completion)
Sets completion to be the auxiliary completion object to use with entry. All
further configuration of the completion mechanism is done on completion using the
EntryCompletion API. Completion is disabled if completion is set
to null.
-
public void set_cursor_hadjustment (Adjustment adjustment)
Hooks up an adjustment to the cursor position in an entry, so that when the cursor is moved, the
adjustment is scrolled to show that position. See get_hadjustment
for a typical way of obtaining the adjustment.
-
public void set_has_frame (bool setting)
Sets whether the entry has a beveled frame around it.
-
public void set_icon_activatable (EntryIconPosition icon_pos, bool activatable)
Sets whether the icon is activatable.
-
public void set_icon_drag_source (EntryIconPosition icon_pos, TargetList target_list, DragAction actions)
Sets up the icon at the given position so that GTK+ will start a drag operation when the user clicks
and drags the icon.
-
public void set_icon_from_gicon (EntryIconPosition icon_pos, Icon? 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.
-
public void set_icon_from_icon_name (EntryIconPosition icon_pos, string? icon_name)
Sets the icon shown in the entry at the specified position from the current icon theme.
-
public void set_icon_from_pixbuf (EntryIconPosition icon_pos, Pixbuf? pixbuf)
Sets the icon shown in the specified position using a pixbuf.
-
public void set_icon_from_stock (EntryIconPosition icon_pos, string? stock_id)
Sets the icon shown in the entry at the specified position from a stock image.
-
public void set_icon_sensitive (EntryIconPosition icon_pos, bool sensitive)
Sets the sensitivity for the specified icon.
-
public void set_icon_tooltip_markup (EntryIconPosition icon_pos, string? tooltip)
Sets tooltip as the contents of the tooltip for the icon at the specified position.
tooltip is assumed to be marked up with the Pango text markup language.
-
public void set_icon_tooltip_text (EntryIconPosition icon_pos, string? tooltip)
Sets tooltip as the contents of the tooltip for the icon at the specified position.
-
public void set_inner_border (Border border)
Sets entry's inner-border property to border, or clears it if null
is passed. The inner-border is the area around the entry's text, but inside its frame.
-
public void set_invisible_char (unichar ch)
Sets the character to use in place of the actual text when
set_visibility has been called to set text visibility to false
. i.e. this is the character used in "password mode" to show the user how many characters have been typed. By default, GTK+
picks the best invisible char available in the current font. If you set the invisible char to 0, then the user will get no feedback
at all; there will be no text on the screen as they type.
-
public void set_max_length (int max)
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.
-
public void set_overwrite_mode (bool overwrite)
Sets whether the text is overwritten when typing in the Entry
.
-
public void set_progress_fraction (double fraction)
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.
-
public void set_progress_pulse_step (double fraction)
Sets the fraction of total entry width to move the progress bouncing block for each call to
progress_pulse.
-
public void set_text (string text)
Sets the text in the widget to the given value, replacing the current contents.
-
public void set_visibility (bool visible)
Sets whether the contents of the entry are visible or not. When visibility is set to false
, characters are displayed as the invisible char, and will also appear that way when the text in the entry widget is copied
elsewhere.
-
public void set_width_chars (int n_chars)
Changes the size request of the entry to be about the right size for n_chars characters.
Note that it changes the size request, the size can still be affected by how you pack the widget into containers. If
n_chars is -1, the size reverts to the default entry size.
-
public int text_index_to_layout_index (int text_index)
Converts from a position in the entry's Layout
(returned by get_layout) to a position in the entry contents (returned by
get_text).
-
public void unset_invisible_char ()
Unsets the invisible char previously set with
set_invisible_char. So that the default invisible char is used again.