Top | ![]() |
![]() |
![]() |
![]() |
DhWebView * | dh_web_view_new () |
DhProfile * | dh_web_view_get_profile () |
const gchar * | dh_web_view_get_devhelp_title () |
void | dh_web_view_set_search_text () |
void | dh_web_view_search_next () |
void | dh_web_view_search_previous () |
gboolean | dh_web_view_can_zoom_in () |
gboolean | dh_web_view_can_zoom_out () |
gboolean | dh_web_view_can_reset_zoom () |
void | dh_web_view_zoom_in () |
void | dh_web_view_zoom_out () |
void | dh_web_view_reset_zoom () |
GObject ╰── GInitiallyUnowned ╰── GtkWidget ╰── GtkContainer ╰── WebKitWebViewBase ╰── WebKitWebView ╰── DhWebView
DhWebView is a subclass of WebKitWebView, to have a higher-level API for some features, and with some customizations for the libdevhelp use-case.
Features:
Ctrl+scroll to zoom in/zoom out.
Sending the “open-new-tab” signal on middle click or Ctrl+click on a link (DhNotebook handles that signal).
Calls gtk_show_uri_on_window()
when opening a non-local link (for example a
http://
URL).
The DhProfile is used for:
Applying the DhSettings fonts.
When trying to load a remote URL from developer.gnome.org, find in the
DhBookList if there is an equivalent local link to load it instead of
opening the URL with gtk_show_uri_on_window()
.
const gchar *
dh_web_view_get_devhelp_title (DhWebView *view
);
An enhanced getter function for the “title” property: when that
property is the empty string or NULL
, this function returns “Empty Page”
(translated).
Since: 3.30
void dh_web_view_set_search_text (DhWebView *view
,const gchar *search_text
);
A more convenient API (for Devhelp needs) than WebKitFindController. If
search_text
is not empty, it calls webkit_find_controller_search()
if not
already done. If search_text
is empty or NULL
, it calls
webkit_find_controller_search_finish()
.
Since: 3.30
void
dh_web_view_search_next (DhWebView *view
);
Like webkit_find_controller_search_next()
, but takes into account whether
dh_web_view_set_search_text()
has been called.
Since: 3.30
void
dh_web_view_search_previous (DhWebView *view
);
Like webkit_find_controller_search_previous()
, but takes into account whether
dh_web_view_set_search_text()
has been called.
Since: 3.30
void
dh_web_view_zoom_in (DhWebView *view
);
Makes the text larger.
Since: 3.30
void
dh_web_view_zoom_out (DhWebView *view
);
Makes the text smaller.
Since: 3.30
“profile”
property“profile” DhProfile *
The DhProfile. If set to NULL
, the default profile as returned by
dh_profile_get_default()
is used.
Flags: Read / Write / Construct Only
Since: 3.30
“open-new-tab”
signalvoid user_function (DhWebView *view, gchar *uri, gpointer user_data)
The ::open-new-tab signal is emitted when a URI needs to be opened in a new DhWebView. This happens when doing Ctrl+click or middle click on a link.
view |
the DhWebView emitting the signal. |
|
uri |
the URI to open. |
|
user_data |
user data set when the signal handler was connected. |
Flags: Run Last
Since: 3.30