NetSurf
|
find in page gtk frontend implementation More...
#include <stdlib.h>
#include <stdbool.h>
#include <gtk/gtk.h>
#include "utils/nsoption.h"
#include "netsurf/search.h"
#include "desktop/search.h"
#include "gtk/compat.h"
#include "gtk/toolbar_items.h"
#include "gtk/window.h"
#include "gtk/search.h"
Go to the source code of this file.
Data Structures | |
struct | gtk_search |
Functions | |
static void | nsgtk_search_set_forward_state (bool active, struct gtk_search *search) |
activate search forwards button in gui. More... | |
static void | nsgtk_search_set_back_state (bool active, struct gtk_search *search) |
activate search back button in gui. More... | |
static gboolean | nsgtk_search_forward_button_clicked (GtkWidget *widget, gpointer data) |
connected to the search forward button More... | |
static gboolean | nsgtk_search_back_button_clicked (GtkWidget *widget, gpointer data) |
connected to the search back button More... | |
static gboolean | nsgtk_search_close_button_clicked (GtkWidget *widget, gpointer data) |
connected to the search close button More... | |
static gboolean | nsgtk_search_entry_changed (GtkWidget *widget, gpointer data) |
connected to the search entry [typing] More... | |
static gboolean | nsgtk_search_entry_activate (GtkWidget *widget, gpointer data) |
connected to the search entry [return key] More... | |
static gboolean | nsgtk_search_entry_key (GtkWidget *widget, GdkEventKey *event, gpointer data) |
allows escape key to close search bar too More... | |
nserror | nsgtk_search_toggle_visibility (struct gtk_search *search) |
toggle search bar visibility More... | |
nserror | nsgtk_search_restyle (struct gtk_search *search) |
update search toolbar size and style More... | |
nserror | nsgtk_search_create (GtkBuilder *builder, struct browser_window *bw, struct gtk_search **search_out) |
create text search context More... | |
Variables | |
static struct gui_search_table | search_table |
struct gui_search_table * | nsgtk_search_table = &search_table |
find in page gtk frontend implementation
Definition in file search.c.
|
static |
connected to the search back button
Definition at line 109 of file search.c.
References browser_window_search(), gtk_search::bw, gtk_search::caseSens, gtk_search::checkAll, gtk_search::entry, SEARCH_FLAG_CASE_SENSITIVE, and SEARCH_FLAG_SHOWALL.
Referenced by nsgtk_search_create().
|
static |
connected to the search close button
Definition at line 136 of file search.c.
References nsgtk_search_toggle_visibility().
Referenced by nsgtk_search_create().
nserror nsgtk_search_create | ( | GtkBuilder * | builder, |
struct browser_window * | bw, | ||
struct gtk_search ** | search | ||
) |
create text search context
builder | the gtk builder containing the search toolbar |
bw | The browsing context to run the find operations against |
search | search context result |
Definition at line 284 of file search.c.
References gtk_search::back, gtk_search::bar, gtk_search::bw, gtk_search::caseSens, gtk_search::checkAll, gtk_search::close, gtk_search::entry, gtk_search::forward, NSERROR_NOMEM, NSERROR_OK, nsgtk_search_back_button_clicked(), nsgtk_search_close_button_clicked(), nsgtk_search_entry_activate(), nsgtk_search_entry_changed(), nsgtk_search_entry_key(), nsgtk_search_forward_button_clicked(), and nsgtk_search_restyle().
Referenced by gui_window_create().
|
static |
connected to the search entry [return key]
Definition at line 177 of file search.c.
References browser_window_search(), gtk_search::bw, gtk_search::caseSens, gtk_search::checkAll, gtk_search::entry, SEARCH_FLAG_CASE_SENSITIVE, SEARCH_FLAG_FORWARDS, and SEARCH_FLAG_SHOWALL.
Referenced by nsgtk_search_create().
|
static |
connected to the search entry [typing]
Definition at line 151 of file search.c.
References browser_window_search(), gtk_search::bw, gtk_search::caseSens, gtk_search::checkAll, gtk_search::entry, SEARCH_FLAG_CASE_SENSITIVE, and SEARCH_FLAG_SHOWALL.
Referenced by nsgtk_search_create(), and nsgtk_search_toggle_visibility().
|
static |
allows escape key to close search bar too
Definition at line 204 of file search.c.
References GDK_KEY, and nsgtk_search_toggle_visibility().
Referenced by nsgtk_search_create().
|
static |
connected to the search forward button
Definition at line 82 of file search.c.
References browser_window_search(), gtk_search::bw, gtk_search::caseSens, gtk_search::checkAll, gtk_search::entry, SEARCH_FLAG_CASE_SENSITIVE, SEARCH_FLAG_FORWARDS, and SEARCH_FLAG_SHOWALL.
Referenced by nsgtk_search_create().
nserror nsgtk_search_restyle | ( | struct gtk_search * | search | ) |
update search toolbar size and style
Definition at line 245 of file search.c.
References gtk_search::bar, NSERROR_OK, and nsoption_int.
Referenced by nsgtk_search_create(), and nsgtk_window_update_all().
|
static |
activate search back button in gui.
active | activate/inactivate |
search | the gtk search context |
Definition at line 72 of file search.c.
References gtk_search::back.
|
static |
activate search forwards button in gui.
active | activate/inactivate |
search | the gtk search context |
Definition at line 60 of file search.c.
References gtk_search::forward.
nserror nsgtk_search_toggle_visibility | ( | struct gtk_search * | search | ) |
toggle search bar visibility
Definition at line 225 of file search.c.
References gtk_search::bar, browser_window_search_clear(), gtk_search::bw, gtk_search::entry, NSERROR_OK, and nsgtk_search_entry_changed().
Referenced by gui_window_create(), nsgtk_search_close_button_clicked(), nsgtk_search_entry_key(), and nsgtk_window_search_toggle().
struct gui_search_table* nsgtk_search_table = &search_table |
|
static |