EntryBuffer
Object Hierarchy:
Description:
public class EntryBuffer :
Object
Holds the text that is displayed in a single-line text entry widget.
A single `GtkEntryBuffer` object can be shared by multiple widgets which will then share the same text content, but not the cursor
position, visibility attributes, icon etc.
`GtkEntryBuffer` may be derived from. Such a derived class might allow text to be stored in an alternate location, such as non-pageable
memory, useful in the case of important passwords. Or a derived class could integrate with an application’s concept of undo/redo.
Content:
Properties:
- public uint length { get; }
The length (in characters) of the text in buffer.
- public int max_length { get; set; }
The maximum length (in characters) of the text in the buffer.
- public string text { get; set; }
The contents of the buffer.
Creation methods:
Methods:
- public virtual uint delete_text (uint position, int n_chars)
Deletes a sequence of characters from the buffer.
- public void emit_deleted_text (uint position, uint n_chars)
Used when subclassing `GtkEntryBuffer`.
- public void emit_inserted_text (uint position, uint8[] chars)
Used when subclassing `GtkEntryBuffer`.
- public size_t get_bytes ()
Retrieves the length in bytes of the buffer.
- public virtual uint get_length ()
Retrieves the length in characters of the buffer.
- public int get_max_length ()
Retrieves the maximum allowed length of the text in
this.
- public virtual unowned string get_text ()
Retrieves the contents of the buffer.
- public virtual uint insert_text (uint position, uint8[] chars)
Inserts n_chars characters of chars into the
contents of the buffer, at position position.
- public void set_max_length (int max_length)
Sets the maximum allowed length of the contents of the buffer.
- public void set_text (uint8[] chars)
Sets the text in the buffer.
Signals:
Inherited Members:
All known members inherited from class GLib.Object