Top |
Functions
RBSearchEntry * | rb_search_entry_new () |
void | rb_search_entry_clear () |
void | rb_search_entry_set_text () |
gboolean | rb_search_entry_searching () |
void | rb_search_entry_grab_focus () |
Object Hierarchy
GObject ╰── GInitiallyUnowned ╰── GtkWidget ╰── GtkContainer ╰── GtkBox ╰── RBSearchEntry
Implemented Interfaces
RBSearchEntry implements AtkImplementorIface, GtkBuildable and GtkOrientable.
Description
The search entry contains a label and a text entry box. The text entry box contains an icon that acts as a 'clear' button.
Signals are emitted when the search text changes, arbitrarily rate-limited to one every 300ms.
Functions
rb_search_entry_new ()
RBSearchEntry *
rb_search_entry_new (gboolean has_popup
);
Creates a new search entry widget.
rb_search_entry_clear ()
void
rb_search_entry_clear (RBSearchEntry *entry
);
Clears the search entry text. The 'search' signal will be emitted.
rb_search_entry_set_text ()
void rb_search_entry_set_text (RBSearchEntry *entry
,const char *text
);
Sets the text in the search entry box. The 'search' signal will be emitted.
rb_search_entry_searching ()
gboolean
rb_search_entry_searching (RBSearchEntry *entry
);
Returns TRUE
if there is search text in the entry widget.
rb_search_entry_grab_focus ()
void
rb_search_entry_grab_focus (RBSearchEntry *entry
);
Grabs input focus for the text entry widget.
Property Details
The “explicit-mode”
property
“explicit-mode” gboolean
If TRUE, show a button and only emit the 'search' signal when the user presses it rather than when they stop typing.
Flags: Read / Write
Default value: FALSE
The “has-popup”
property
“has-popup” gboolean
If TRUE, show a primary icon and emit the show-popup when clicked.
Flags: Read / Write / Construct Only
Default value: FALSE
Signal Details
The “activate”
signal
void user_function (RBSearchEntry *entry, gchar *text, gpointer user_data)
Emitted when the entry is activated.
Parameters
entry |
the RBSearchEntry |
|
text |
search text |
|
user_data |
user data set when the signal handler was connected. |
Flags: Run Last
The “search”
signal
void user_function (RBSearchEntry *entry, gchar *text, gpointer user_data)
Emitted when the search text changes. A signal handler must initiate a search on the current source.
Parameters
entry |
the RBSearchEntry |
|
text |
search text |
|
user_data |
user data set when the signal handler was connected. |
Flags: Run Last
The “show-popup”
signal
void user_function (RBSearchEntry *entry, gpointer user_data)
Emitted when a popup menu should be shown
Flags: Run Last