pub struct Settings { /* private fields */ }
Expand description
Control the behaviour of a #WebKitWebView.
#WebKitSettings can be applied to a #WebKitWebView to control text charset, color, font sizes, printing mode, script support, loading of images and various other things on a #WebKitWebView. After creation, a #WebKitSettings object contains default settings.
⚠️ The following code is in c ⚠️
// Disable JavaScript
WebKitSettings *settings = webkit_web_view_group_get_settings (my_view_group);
webkit_settings_set_enable_javascript (settings, FALSE);
§Properties
§allow-file-access-from-file-urls
Whether file access is allowed from file URLs. By default, when something is loaded in a #WebKitWebView using a file URI, cross origin requests to other file resources are not allowed. This setting allows you to change that behaviour, so that it would be possible to do a XMLHttpRequest of a local file, for example.
Readable | Writeable | Construct
§allow-modal-dialogs
Determine whether it’s allowed to create and run modal dialogs
from a #WebKitWebView through JavaScript with
false
, the associated #WebKitWebView won’t be able to create
new modal dialogs, so not even the #WebKitWebView::create
signal will be emitted.
Readable | Writeable | Construct
§allow-top-navigation-to-data-urls
Whether or not the top frame is allowed to navigate to data URLs. It is disabled by default due to the risk it poses when loading untrusted URLs, with data URLs being used in scamming and phishing attacks. In contrast, a scenario where it could be enabled could be an app that embeds a WebView and you have control of the pages being show instead of a generic browser.
Readable | Writeable | Construct
§allow-universal-access-from-file-urls
Whether or not JavaScript running in the context of a file scheme URL should be allowed to access content from any origin. By default, when something is loaded in a #WebKitWebView using a file scheme URL, access to the local file system and arbitrary local storage is not allowed. This setting allows you to change that behaviour, so that it would be possible to use local storage, for example.
Readable | Writeable | Construct
§auto-load-images
Determines whether images should be automatically loaded or not. On devices where network bandwidth is of concern, it might be useful to turn this property off.
Readable | Writeable | Construct
§cursive-font-family
The font family used as the default for content using a cursive font.
Readable | Writeable | Construct
§default-charset
The default text charset used when interpreting content with an unspecified charset.
Readable | Writeable | Construct
§default-font-family
The font family to use as the default for content that does not specify a font.
Readable | Writeable | Construct
§default-font-size
The default font size in pixels to use for content displayed if no font size is specified.
Readable | Writeable | Construct
§default-monospace-font-size
The default font size in pixels to use for content displayed in monospace font if no font size is specified.
Readable | Writeable | Construct
§disable-web-security
Enable or disable support for Web Security on pages.
This setting disables the same-origin policy, allowing every website full control over all other websites. This is for use in special environments where you wish to disable all security and allow websites to hack each other. It is impossible to use this setting securely.
Readable | Writeable | Construct
§draw-compositing-indicators
Whether to draw compositing borders and repaint counters on layers drawn with accelerated compositing. This is useful for debugging issues related to web content that is composited with the GPU.
Readable | Writeable | Construct
§enable-2d-canvas-acceleration
Enable or disable 2D canvas acceleration. If this setting is enabled, the 2D canvas will be accelerated even if Skia CPU is used for rendering. However, the canvas can be unaccelerated even when this setting is enabled, for other reasons like its size or when willReadFrequently property is used.
Readable | Writeable | Construct
§enable-back-forward-navigation-gestures
Enable or disable horizontal swipe gesture for back-forward navigation.
Readable | Writeable | Construct
§enable-caret-browsing
Whether to enable accessibility enhanced keyboard navigation.
Readable | Writeable | Construct
§enable-developer-extras
Determines whether or not developer tools, such as the Web Inspector, are enabled.
Readable | Writeable | Construct
§enable-dns-prefetching
Determines whether or not to prefetch domain names. DNS prefetching attempts to resolve domain names before a user tries to follow a link.
Readable | Writeable | Construct
§enable-encrypted-media
Enable or disable support for Encrypted Media API on pages. EncryptedMedia is an experimental JavaScript API for playing encrypted media in HTML. This property will only work as intended if the EncryptedMedia feature is enabled at build time with the ENABLE_ENCRYPTED_MEDIA flag.
See https://www.w3.org/TR/encrypted-media/
Readable | Writeable | Construct
§enable-fullscreen
Whether to enable the Javascript Fullscreen API. The API allows any HTML element to request fullscreen display. See also the current draft of the spec: http://www.w3.org/TR/fullscreen/
Readable | Writeable | Construct
§enable-html5-database
Whether to enable HTML5 client-side SQL database support (IndexedDB).
Readable | Writeable | Construct
§enable-html5-local-storage
Whether to enable HTML5 local storage support. Local storage provides simple synchronous storage access.
HTML5 local storage specification is available at http://dev.w3.org/html5/webstorage/.
Readable | Writeable | Construct
§enable-hyperlink-auditing
Determines whether or not hyperlink auditing is enabled.
The hyperlink auditing specification is available at http://www.whatwg.org/specs/web-apps/current-work/multipage/links.html#hyperlink-auditing.
Readable | Writeable | Construct
§enable-javascript
Determines whether or not JavaScript executes within a page.
Readable | Writeable | Construct
§enable-javascript-markup
Determines whether or not JavaScript markup is allowed in document. When this setting is disabled,
all JavaScript-related elements and attributes are removed from the document during parsing. Note that
executing JavaScript is still allowed if #WebKitSettings:enable-javascript is true
.
Readable | Writeable | Construct
§enable-media
Enable or disable support for media playback on pages. This setting is enabled by
default. Disabling it means <audio>
, <track>
and <video>
elements will have
playback support disabled.
Readable | Writeable | Construct
§enable-media-capabilities
Enable or disable support for MediaCapabilities on pages. This specification intends to provide APIs to allow websites to make an optimal decision when picking media content for the user. The APIs will expose information about the decoding and encoding capabilities for a given format but also output capabilities to find the best match based on the device’s display.
See also https://wicg.github.io/media-capabilities/
Readable | Writeable | Construct
§enable-media-stream
Enable or disable support for MediaStream on pages. MediaStream is an experimental proposal for allowing web pages to access audio and video devices for capture.
See also http://dev.w3.org/2011/webrtc/editor/getusermedia.html
Readable | Writeable | Construct
§enable-mediasource
Enable or disable support for MediaSource on pages. MediaSource extends HTMLMediaElement to allow JavaScript to generate media streams for playback.
See also http://www.w3.org/TR/media-source/
Readable | Writeable | Construct
§enable-mock-capture-devices
Enable or disable the Mock Capture Devices. Those are fake Microphone and Camera devices to be used as MediaStream sources.
Readable | Writeable | Construct
§enable-offline-web-application-cache
Unsupported setting. This property does nothing.
Readable | Writeable | Construct
§enable-page-cache
Enable or disable the page cache. Disabling the page cache is generally only useful for special circumstances like low-memory scenarios or special purpose applications like static HTML viewers. This setting only controls the Page Cache, this cache is different than the disk-based or memory-based traditional resource caches, its point is to make going back and forth between pages much faster. For details about the different types of caches and their purposes see: http://webkit.org/blog/427/webkit-page-cache-i-the-basics/
Readable | Writeable | Construct
§enable-resizable-text-areas
Determines whether or not text areas can be resized.
Readable | Writeable | Construct
§enable-site-specific-quirks
Whether to turn on site-specific quirks. Turning this on will tell WebKit to use some site-specific workarounds for better web compatibility. For example, older versions of MediaWiki will incorrectly send to WebKit a CSS file with KHTML workarounds. By turning on site-specific quirks, WebKit will special-case this and other cases to make some specific sites work.
Readable | Writeable | Construct
§enable-smooth-scrolling
Enable or disable smooth scrolling.
Readable | Writeable | Construct
§enable-spatial-navigation
Whether to enable Spatial Navigation. This feature consists in the ability to navigate between focusable elements in a Web page, such as hyperlinks and form controls, by using Left, Right, Up and Down arrow keys. For example, if an user presses the Right key, heuristics determine whether there is an element they might be trying to reach towards the right, and if there are multiple elements, which element they probably wants.
Readable | Writeable | Construct
§enable-tabs-to-links
Determines whether the tab key cycles through the elements on the page. When this setting is enabled, users will be able to focus the next element in the page by pressing the tab key. If the selected element is editable, then pressing tab key will insert the tab character.
Readable | Writeable | Construct
§enable-webaudio
Enable or disable support for WebAudio on pages. WebAudio is an API for processing and synthesizing audio in web applications
See also https://webaudio.github.io/web-audio-api
Readable | Writeable | Construct
§enable-webgl
Enable or disable support for WebGL on pages. WebGL enables web content to use an API based on OpenGL ES 2.0.
Readable | Writeable | Construct
§enable-webrtc
Enable WebRTC support for loaded pages.
Enabling this setting implies that enable-media-stream
will be enabled as well.
See also https://www.w3.org/TR/webrtc/
Readable | Writeable | Construct
§enable-write-console-messages-to-stdout
Enable or disable writing console messages to stdout. These are messages sent to the console with console.log and related methods.
Readable | Writeable | Construct
§fantasy-font-family
The font family used as the default for content using a fantasy font.
Readable | Writeable | Construct
§hardware-acceleration-policy
The #WebKitHardwareAccelerationPolicy to decide how to enable and disable hardware acceleration. Disabling hardware acceleration might cause some websites to not render correctly or consume more CPU.
Note that changing this setting might not be possible if hardware acceleration is not supported by the hardware or the system. In that case, you can get the value to know the actual policy being used, but changing the setting will not have any effect.
Readable | Writeable | Construct
§javascript-can-access-clipboard
Whether JavaScript can access the clipboard. The default value is false
. If
set to true
, document.execCommand() allows cut, copy and paste commands.
Readable | Writeable | Construct
§javascript-can-open-windows-automatically
Whether JavaScript can open popup windows automatically without user intervention.
Readable | Writeable | Construct
§load-icons-ignoring-image-load-setting
Unsupported setting. This property does nothing.
Readable | Writeable | Construct
§media-content-types-requiring-hardware-support
List of media content types requiring hardware support, split by semicolons (:). For example: ‘video/webm; codecs=“vp*”:video/mp4; codecs=“avc*”:video/* codecs=“av1*”’.
Readable | Writeable | Construct
§media-playback-allows-inline
Whether media playback is full-screen only or inline playback is allowed.
This is true
by default, so media playback can be inline. Setting it to
false
allows specifying that media playback should be always fullscreen.
Readable | Writeable | Construct
§media-playback-requires-user-gesture
Whether a user gesture (such as clicking the play button) would be required to start media playback or load media. This is off by default, so media playback could start automatically. Setting it on requires a gesture by the user to start playback, or to load the media.
Readable | Writeable | Construct
§minimum-font-size
The minimum font size in pixels used to display text. This setting controls the absolute smallest size. Values other than 0 can potentially break page layouts.
Readable | Writeable | Construct
§monospace-font-family
The font family used as the default for content using a monospace font.
Readable | Writeable | Construct
§pictograph-font-family
The font family used as the default for content using a pictograph font.
Readable | Writeable | Construct
§print-backgrounds
Whether background images should be drawn during printing.
Readable | Writeable | Construct
§sans-serif-font-family
The font family used as the default for content using a sans-serif font.
Readable | Writeable | Construct
§serif-font-family
The font family used as the default for content using a serif font.
Readable | Writeable | Construct
§user-agent
The user-agent string used by WebKit. Unusual user-agent strings may cause web content to render incorrectly or fail to run, as many web pages are written to parse the user-agent strings of only the most popular browsers. Therefore, it’s typically better to not completely override the standard user-agent, but to use webkit_settings_set_user_agent_with_application_details() instead.
If this property is set to the empty string or None
, it will revert to the standard
user-agent.
Readable | Writeable | Construct
§zoom-text-only
Whether #WebKitWebView:zoom-level affects only the text of the page or all the contents. Other contents containing text like form controls will be also affected by zoom factor when this property is enabled.
Readable | Writeable | Construct
GLib type: GObject with reference counted clone semantics.
Implementations§
source§impl Settings
impl Settings
sourcepub fn new() -> Settings
pub fn new() -> Settings
Creates a new #WebKitSettings instance with default values.
It must be manually attached to a #WebKitWebView. See also webkit_settings_new_with_settings().
§Returns
a new #WebKitSettings instance.
sourcepub fn builder() -> SettingsBuilder
pub fn builder() -> SettingsBuilder
Creates a new builder-pattern struct instance to construct Settings
objects.
This method returns an instance of SettingsBuilder
which can be used to create Settings
objects.
sourcepub fn apply_from_key_file(
&self,
key_file: &KeyFile,
group_name: &str,
) -> Result<(), Error>
Available on crate feature v2_46
only.
pub fn apply_from_key_file( &self, key_file: &KeyFile, group_name: &str, ) -> Result<(), Error>
v2_46
only.Reads the contents of the given @group_name from the given @key_file and apply the value of each key/value to the corresponding property on the @self.
Value types have to match with the corresponding setting property type and the group keys have to
match existing setting property names. If those conditions are not met, the function will return
false
.
Supported value types are strings (unquoted), booleans (0, 1, true, false) and unsigned integers.
§key_file
a #GKeyFile
§group_name
Name of the group to read from @key_file
§Returns
true
if the settings were correctly applied or false
on error.
sourcepub fn allows_file_access_from_file_urls(&self) -> bool
pub fn allows_file_access_from_file_urls(&self) -> bool
sourcepub fn allows_modal_dialogs(&self) -> bool
pub fn allows_modal_dialogs(&self) -> bool
sourcepub fn allows_universal_access_from_file_urls(&self) -> bool
pub fn allows_universal_access_from_file_urls(&self) -> bool
sourcepub fn is_auto_load_images(&self) -> bool
pub fn is_auto_load_images(&self) -> bool
sourcepub fn cursive_font_family(&self) -> Option<GString>
pub fn cursive_font_family(&self) -> Option<GString>
Gets the #WebKitSettings:cursive-font-family property.
§Returns
The default font family used to display content marked with cursive font.
sourcepub fn default_charset(&self) -> Option<GString>
pub fn default_charset(&self) -> Option<GString>
sourcepub fn default_font_family(&self) -> Option<GString>
pub fn default_font_family(&self) -> Option<GString>
Gets the #WebKitSettings:default-font-family property.
§Returns
The default font family used to display content that does not specify a font.
sourcepub fn default_font_size(&self) -> u32
pub fn default_font_size(&self) -> u32
sourcepub fn default_monospace_font_size(&self) -> u32
pub fn default_monospace_font_size(&self) -> u32
Gets the #WebKitSettings:default-monospace-font-size property.
§Returns
Default monospace font size, in pixels.
sourcepub fn is_disable_web_security(&self) -> bool
pub fn is_disable_web_security(&self) -> bool
sourcepub fn draws_compositing_indicators(&self) -> bool
pub fn draws_compositing_indicators(&self) -> bool
sourcepub fn enables_2d_canvas_acceleration(&self) -> bool
Available on crate feature v2_46
only.
pub fn enables_2d_canvas_acceleration(&self) -> bool
v2_46
only.sourcepub fn enables_caret_browsing(&self) -> bool
pub fn enables_caret_browsing(&self) -> bool
sourcepub fn enables_developer_extras(&self) -> bool
pub fn enables_developer_extras(&self) -> bool
sourcepub fn enables_dns_prefetching(&self) -> bool
pub fn enables_dns_prefetching(&self) -> bool
sourcepub fn enables_encrypted_media(&self) -> bool
pub fn enables_encrypted_media(&self) -> bool
sourcepub fn enables_fullscreen(&self) -> bool
pub fn enables_fullscreen(&self) -> bool
sourcepub fn enables_html5_database(&self) -> bool
pub fn enables_html5_database(&self) -> bool
sourcepub fn enables_html5_local_storage(&self) -> bool
pub fn enables_html5_local_storage(&self) -> bool
sourcepub fn enables_hyperlink_auditing(&self) -> bool
pub fn enables_hyperlink_auditing(&self) -> bool
sourcepub fn enables_javascript(&self) -> bool
pub fn enables_javascript(&self) -> bool
sourcepub fn enables_javascript_markup(&self) -> bool
pub fn enables_javascript_markup(&self) -> bool
sourcepub fn enables_media(&self) -> bool
pub fn enables_media(&self) -> bool
sourcepub fn enables_media_capabilities(&self) -> bool
pub fn enables_media_capabilities(&self) -> bool
sourcepub fn enables_media_stream(&self) -> bool
pub fn enables_media_stream(&self) -> bool
sourcepub fn enables_mediasource(&self) -> bool
pub fn enables_mediasource(&self) -> bool
sourcepub fn enables_mock_capture_devices(&self) -> bool
pub fn enables_mock_capture_devices(&self) -> bool
sourcepub fn enables_offline_web_application_cache(&self) -> bool
👎Deprecated: Since 2.44
pub fn enables_offline_web_application_cache(&self) -> bool
sourcepub fn enables_page_cache(&self) -> bool
pub fn enables_page_cache(&self) -> bool
sourcepub fn enables_resizable_text_areas(&self) -> bool
pub fn enables_resizable_text_areas(&self) -> bool
sourcepub fn enables_site_specific_quirks(&self) -> bool
pub fn enables_site_specific_quirks(&self) -> bool
sourcepub fn enables_smooth_scrolling(&self) -> bool
pub fn enables_smooth_scrolling(&self) -> bool
sourcepub fn enables_tabs_to_links(&self) -> bool
pub fn enables_tabs_to_links(&self) -> bool
sourcepub fn enables_webaudio(&self) -> bool
pub fn enables_webaudio(&self) -> bool
sourcepub fn enables_webgl(&self) -> bool
pub fn enables_webgl(&self) -> bool
sourcepub fn enables_webrtc(&self) -> bool
pub fn enables_webrtc(&self) -> bool
sourcepub fn enables_write_console_messages_to_stdout(&self) -> bool
pub fn enables_write_console_messages_to_stdout(&self) -> bool
sourcepub fn fantasy_font_family(&self) -> Option<GString>
pub fn fantasy_font_family(&self) -> Option<GString>
Gets the #WebKitSettings:fantasy-font-family property.
§Returns
The default font family used to display content marked with fantasy font.
sourcepub fn is_feature_enabled(&self, feature: &Feature) -> bool
Available on crate feature v2_42
only.
pub fn is_feature_enabled(&self, feature: &Feature) -> bool
v2_42
only.sourcepub fn hardware_acceleration_policy(&self) -> HardwareAccelerationPolicy
pub fn hardware_acceleration_policy(&self) -> HardwareAccelerationPolicy
Get the #WebKitSettings:hardware-acceleration-policy property.
§Returns
a #WebKitHardwareAccelerationPolicy
sourcepub fn is_javascript_can_access_clipboard(&self) -> bool
pub fn is_javascript_can_access_clipboard(&self) -> bool
sourcepub fn is_javascript_can_open_windows_automatically(&self) -> bool
pub fn is_javascript_can_open_windows_automatically(&self) -> bool
sourcepub fn is_load_icons_ignoring_image_load_setting(&self) -> bool
👎Deprecated: Since 2.42
pub fn is_load_icons_ignoring_image_load_setting(&self) -> bool
sourcepub fn media_content_types_requiring_hardware_support(&self) -> Option<GString>
pub fn media_content_types_requiring_hardware_support(&self) -> Option<GString>
sourcepub fn is_media_playback_allows_inline(&self) -> bool
pub fn is_media_playback_allows_inline(&self) -> bool
sourcepub fn is_media_playback_requires_user_gesture(&self) -> bool
pub fn is_media_playback_requires_user_gesture(&self) -> bool
sourcepub fn minimum_font_size(&self) -> u32
pub fn minimum_font_size(&self) -> u32
sourcepub fn monospace_font_family(&self) -> Option<GString>
pub fn monospace_font_family(&self) -> Option<GString>
Gets the #WebKitSettings:monospace-font-family property.
§Returns
Default font family used to display content marked with monospace font.
sourcepub fn pictograph_font_family(&self) -> Option<GString>
pub fn pictograph_font_family(&self) -> Option<GString>
Gets the #WebKitSettings:pictograph-font-family property.
§Returns
The default font family used to display content marked with pictograph font.
sourcepub fn is_print_backgrounds(&self) -> bool
pub fn is_print_backgrounds(&self) -> bool
sourcepub fn sans_serif_font_family(&self) -> Option<GString>
pub fn sans_serif_font_family(&self) -> Option<GString>
Gets the #WebKitSettings:sans-serif-font-family property.
§Returns
The default font family used to display content marked with sans-serif font.
sourcepub fn serif_font_family(&self) -> Option<GString>
pub fn serif_font_family(&self) -> Option<GString>
Gets the #WebKitSettings:serif-font-family property.
§Returns
The default font family used to display content marked with serif font.
sourcepub fn user_agent(&self) -> Option<GString>
pub fn user_agent(&self) -> Option<GString>
sourcepub fn is_zoom_text_only(&self) -> bool
pub fn is_zoom_text_only(&self) -> bool
sourcepub fn set_allow_file_access_from_file_urls(&self, allowed: bool)
pub fn set_allow_file_access_from_file_urls(&self, allowed: bool)
sourcepub fn set_allow_modal_dialogs(&self, allowed: bool)
pub fn set_allow_modal_dialogs(&self, allowed: bool)
sourcepub fn set_allow_universal_access_from_file_urls(&self, allowed: bool)
pub fn set_allow_universal_access_from_file_urls(&self, allowed: bool)
sourcepub fn set_auto_load_images(&self, enabled: bool)
pub fn set_auto_load_images(&self, enabled: bool)
sourcepub fn set_cursive_font_family(&self, cursive_font_family: &str)
pub fn set_cursive_font_family(&self, cursive_font_family: &str)
Set the #WebKitSettings:cursive-font-family property.
§cursive_font_family
the new default cursive font family
sourcepub fn set_default_charset(&self, default_charset: &str)
pub fn set_default_charset(&self, default_charset: &str)
sourcepub fn set_default_font_family(&self, default_font_family: &str)
pub fn set_default_font_family(&self, default_font_family: &str)
Set the #WebKitSettings:default-font-family property.
§default_font_family
the new default font family
sourcepub fn set_default_font_size(&self, font_size: u32)
pub fn set_default_font_size(&self, font_size: u32)
Set the #WebKitSettings:default-font-size property.
§font_size
default font size to be set in pixels
sourcepub fn set_default_monospace_font_size(&self, font_size: u32)
pub fn set_default_monospace_font_size(&self, font_size: u32)
Set the #WebKitSettings:default-monospace-font-size property.
§font_size
default monospace font size to be set in pixels
sourcepub fn set_disable_web_security(&self, disabled: bool)
pub fn set_disable_web_security(&self, disabled: bool)
sourcepub fn set_draw_compositing_indicators(&self, enabled: bool)
pub fn set_draw_compositing_indicators(&self, enabled: bool)
sourcepub fn set_enable_2d_canvas_acceleration(&self, enabled: bool)
Available on crate feature v2_46
only.
pub fn set_enable_2d_canvas_acceleration(&self, enabled: bool)
v2_46
only.sourcepub fn set_enable_caret_browsing(&self, enabled: bool)
pub fn set_enable_caret_browsing(&self, enabled: bool)
sourcepub fn set_enable_developer_extras(&self, enabled: bool)
pub fn set_enable_developer_extras(&self, enabled: bool)
sourcepub fn set_enable_dns_prefetching(&self, enabled: bool)
pub fn set_enable_dns_prefetching(&self, enabled: bool)
sourcepub fn set_enable_encrypted_media(&self, enabled: bool)
pub fn set_enable_encrypted_media(&self, enabled: bool)
sourcepub fn set_enable_fullscreen(&self, enabled: bool)
pub fn set_enable_fullscreen(&self, enabled: bool)
sourcepub fn set_enable_html5_database(&self, enabled: bool)
pub fn set_enable_html5_database(&self, enabled: bool)
sourcepub fn set_enable_html5_local_storage(&self, enabled: bool)
pub fn set_enable_html5_local_storage(&self, enabled: bool)
sourcepub fn set_enable_hyperlink_auditing(&self, enabled: bool)
pub fn set_enable_hyperlink_auditing(&self, enabled: bool)
sourcepub fn set_enable_javascript(&self, enabled: bool)
pub fn set_enable_javascript(&self, enabled: bool)
sourcepub fn set_enable_javascript_markup(&self, enabled: bool)
pub fn set_enable_javascript_markup(&self, enabled: bool)
sourcepub fn set_enable_media(&self, enabled: bool)
pub fn set_enable_media(&self, enabled: bool)
sourcepub fn set_enable_media_capabilities(&self, enabled: bool)
pub fn set_enable_media_capabilities(&self, enabled: bool)
sourcepub fn set_enable_media_stream(&self, enabled: bool)
pub fn set_enable_media_stream(&self, enabled: bool)
sourcepub fn set_enable_mediasource(&self, enabled: bool)
pub fn set_enable_mediasource(&self, enabled: bool)
sourcepub fn set_enable_mock_capture_devices(&self, enabled: bool)
pub fn set_enable_mock_capture_devices(&self, enabled: bool)
sourcepub fn set_enable_offline_web_application_cache(&self, enabled: bool)
👎Deprecated: Since 2.44
pub fn set_enable_offline_web_application_cache(&self, enabled: bool)
sourcepub fn set_enable_page_cache(&self, enabled: bool)
pub fn set_enable_page_cache(&self, enabled: bool)
sourcepub fn set_enable_resizable_text_areas(&self, enabled: bool)
pub fn set_enable_resizable_text_areas(&self, enabled: bool)
sourcepub fn set_enable_site_specific_quirks(&self, enabled: bool)
pub fn set_enable_site_specific_quirks(&self, enabled: bool)
sourcepub fn set_enable_smooth_scrolling(&self, enabled: bool)
pub fn set_enable_smooth_scrolling(&self, enabled: bool)
sourcepub fn set_enable_tabs_to_links(&self, enabled: bool)
pub fn set_enable_tabs_to_links(&self, enabled: bool)
sourcepub fn set_enable_webaudio(&self, enabled: bool)
pub fn set_enable_webaudio(&self, enabled: bool)
sourcepub fn set_enable_webgl(&self, enabled: bool)
pub fn set_enable_webgl(&self, enabled: bool)
sourcepub fn set_enable_webrtc(&self, enabled: bool)
pub fn set_enable_webrtc(&self, enabled: bool)
Set the enable-webrtc
property.
Setting this property to true
implies the media-stream web-setting will also be enabled.
§enabled
Value to be set
sourcepub fn set_enable_write_console_messages_to_stdout(&self, enabled: bool)
pub fn set_enable_write_console_messages_to_stdout(&self, enabled: bool)
sourcepub fn set_fantasy_font_family(&self, fantasy_font_family: &str)
pub fn set_fantasy_font_family(&self, fantasy_font_family: &str)
Set the #WebKitSettings:fantasy-font-family property.
§fantasy_font_family
the new default fantasy font family
sourcepub fn set_feature_enabled(&self, feature: &Feature, enabled: bool)
Available on crate feature v2_42
only.
pub fn set_feature_enabled(&self, feature: &Feature, enabled: bool)
v2_42
only.Enables or disables a feature.
The current status of the feature can be determined with
[Settings::get_feature_enabled
][crate::Settings::get_feature_enabled]. To reset a feature to its
initial status, pass the value returned by
[Feature::get_default_value
][crate::Feature::get_default_value] as the @enabled parameter.
§feature
the feature to toggle.
§enabled
whether the feature will be enabled.
sourcepub fn set_hardware_acceleration_policy(
&self,
policy: HardwareAccelerationPolicy,
)
pub fn set_hardware_acceleration_policy( &self, policy: HardwareAccelerationPolicy, )
Set the #WebKitSettings:hardware-acceleration-policy property.
§policy
a #WebKitHardwareAccelerationPolicy
sourcepub fn set_javascript_can_access_clipboard(&self, enabled: bool)
pub fn set_javascript_can_access_clipboard(&self, enabled: bool)
sourcepub fn set_javascript_can_open_windows_automatically(&self, enabled: bool)
pub fn set_javascript_can_open_windows_automatically(&self, enabled: bool)
Set the #WebKitSettings:javascript-can-open-windows-automatically property.
§enabled
Value to be set
sourcepub fn set_load_icons_ignoring_image_load_setting(&self, enabled: bool)
👎Deprecated: Since 2.42
pub fn set_load_icons_ignoring_image_load_setting(&self, enabled: bool)
sourcepub fn set_media_content_types_requiring_hardware_support(
&self,
content_types: Option<&str>,
)
pub fn set_media_content_types_requiring_hardware_support( &self, content_types: Option<&str>, )
sourcepub fn set_media_playback_allows_inline(&self, enabled: bool)
pub fn set_media_playback_allows_inline(&self, enabled: bool)
sourcepub fn set_media_playback_requires_user_gesture(&self, enabled: bool)
pub fn set_media_playback_requires_user_gesture(&self, enabled: bool)
sourcepub fn set_minimum_font_size(&self, font_size: u32)
pub fn set_minimum_font_size(&self, font_size: u32)
Set the #WebKitSettings:minimum-font-size property.
§font_size
minimum font size to be set in pixels
sourcepub fn set_monospace_font_family(&self, monospace_font_family: &str)
pub fn set_monospace_font_family(&self, monospace_font_family: &str)
Set the #WebKitSettings:monospace-font-family property.
§monospace_font_family
the new default monospace font family
sourcepub fn set_pictograph_font_family(&self, pictograph_font_family: &str)
pub fn set_pictograph_font_family(&self, pictograph_font_family: &str)
Set the #WebKitSettings:pictograph-font-family property.
§pictograph_font_family
the new default pictograph font family
sourcepub fn set_print_backgrounds(&self, print_backgrounds: bool)
pub fn set_print_backgrounds(&self, print_backgrounds: bool)
sourcepub fn set_sans_serif_font_family(&self, sans_serif_font_family: &str)
pub fn set_sans_serif_font_family(&self, sans_serif_font_family: &str)
Set the #WebKitSettings:sans-serif-font-family property.
§sans_serif_font_family
the new default sans-serif font family
sourcepub fn set_serif_font_family(&self, serif_font_family: &str)
pub fn set_serif_font_family(&self, serif_font_family: &str)
Set the #WebKitSettings:serif-font-family property.
§serif_font_family
the new default serif font family
sourcepub fn set_user_agent(&self, user_agent: Option<&str>)
pub fn set_user_agent(&self, user_agent: Option<&str>)
sourcepub fn set_user_agent_with_application_details(
&self,
application_name: Option<&str>,
application_version: Option<&str>,
)
pub fn set_user_agent_with_application_details( &self, application_name: Option<&str>, application_version: Option<&str>, )
Set the #WebKitSettings:user-agent property by appending the application details.
Set the #WebKitSettings:user-agent property by appending the application details to the default user agent. If no application name or version is given, the default user agent used will be used. If only the version is given, the default engine version is used with the given application name.
§application_name
The application name used for the user agent or None
to use the default user agent.
§application_version
The application version for the user agent or None
to user the default version.
sourcepub fn set_zoom_text_only(&self, zoom_text_only: bool)
pub fn set_zoom_text_only(&self, zoom_text_only: bool)
sourcepub fn font_size_to_pixels(points: u32) -> u32
pub fn font_size_to_pixels(points: u32) -> u32
Convert @points to the equivalent value in pixels.
Convert @points to the equivalent value in pixels, based on the current screen DPI. Applications can use this function to convert font size values in points to font size values in pixels when setting the font size properties of #WebKitSettings.
§points
the font size in points to convert to pixels
§Returns
the equivalent font size in pixels.
sourcepub fn font_size_to_points(pixels: u32) -> u32
pub fn font_size_to_points(pixels: u32) -> u32
Convert @pixels to the equivalent value in points.
Convert @pixels to the equivalent value in points, based on the current screen DPI. Applications can use this function to convert font size values in pixels to font size values in points when getting the font size properties of #WebKitSettings.
§pixels
the font size in pixels to convert to points
§Returns
the equivalent font size in points.
sourcepub fn all_features() -> Option<FeatureList>
Available on crate feature v2_42
only.
pub fn all_features() -> Option<FeatureList>
v2_42
only.Gets the list of all available WebKit features.
Features can be toggled with set_feature_enabled()
,
and their current state determined with
is_feature_enabled()
.
Note that most applications should use
get_development_features()
and
get_experimental_features()
instead.
§Returns
List of all features.
sourcepub fn development_features() -> Option<FeatureList>
Available on crate feature v2_42
only.
pub fn development_features() -> Option<FeatureList>
v2_42
only.Gets the list of available development WebKit features.
The returned features are a subset of those returned by
get_all_features()
, and includes those which
web and WebKit developers might find useful, but in general should
not be exposed to end users; see FeatureStatus
for
more details.
§Returns
List of development features.
sourcepub fn experimental_features() -> Option<FeatureList>
Available on crate feature v2_42
only.
pub fn experimental_features() -> Option<FeatureList>
v2_42
only.Gets the list of available experimental WebKit features.
The returned features are a subset of those returned by
get_all_features()
, and includes those which
certain applications may want to expose to end users; see
FeatureStatus
for more details.
§Returns
List of experimental features.
pub fn connect_allow_file_access_from_file_urls_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_allow_modal_dialogs_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_allow_universal_access_from_file_urls_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_auto_load_images_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_cursive_font_family_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_default_charset_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_default_font_family_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_default_font_size_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_default_monospace_font_size_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_disable_web_security_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_draw_compositing_indicators_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_2d_canvas_acceleration_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
v2_46
only.pub fn connect_enable_caret_browsing_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_developer_extras_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_dns_prefetching_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_encrypted_media_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_fullscreen_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_html5_database_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_html5_local_storage_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_hyperlink_auditing_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_javascript_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_javascript_markup_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_media_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_media_capabilities_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_media_stream_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_mediasource_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_mock_capture_devices_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_offline_web_application_cache_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_page_cache_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_resizable_text_areas_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_site_specific_quirks_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_smooth_scrolling_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_tabs_to_links_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_webaudio_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_webgl_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_webrtc_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_enable_write_console_messages_to_stdout_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_fantasy_font_family_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_hardware_acceleration_policy_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_javascript_can_access_clipboard_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_javascript_can_open_windows_automatically_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_load_icons_ignoring_image_load_setting_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_media_content_types_requiring_hardware_support_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_media_playback_allows_inline_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_media_playback_requires_user_gesture_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_minimum_font_size_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_monospace_font_family_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_pictograph_font_family_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_print_backgrounds_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_sans_serif_font_family_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_serif_font_family_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_user_agent_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
pub fn connect_zoom_text_only_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
Trait Implementations§
source§impl HasParamSpec for Settings
impl HasParamSpec for Settings
source§impl Ord for Settings
impl Ord for Settings
source§fn cmp(&self, other: &Self) -> Ordering
fn cmp(&self, other: &Self) -> Ordering
Comparison for two GObjects.
Compares the memory addresses of the provided objects.
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
source§impl<OT: ObjectType> PartialEq<OT> for Settings
impl<OT: ObjectType> PartialEq<OT> for Settings
source§impl<OT: ObjectType> PartialOrd<OT> for Settings
impl<OT: ObjectType> PartialOrd<OT> for Settings
source§fn partial_cmp(&self, other: &OT) -> Option<Ordering>
fn partial_cmp(&self, other: &OT) -> Option<Ordering>
Partial comparison for two GObjects.
Compares the memory addresses of the provided objects.
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read moresource§impl StaticType for Settings
impl StaticType for Settings
source§fn static_type() -> Type
fn static_type() -> Type
Self
.impl Eq for Settings
Auto Trait Implementations§
impl Freeze for Settings
impl RefUnwindSafe for Settings
impl !Send for Settings
impl !Sync for Settings
impl Unpin for Settings
impl UnwindSafe for Settings
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> Cast for Twhere
T: ObjectType,
impl<T> Cast for Twhere
T: ObjectType,
source§fn upcast<T>(self) -> Twhere
T: ObjectType,
Self: IsA<T>,
fn upcast<T>(self) -> Twhere
T: ObjectType,
Self: IsA<T>,
T
. Read moresource§fn upcast_ref<T>(&self) -> &Twhere
T: ObjectType,
Self: IsA<T>,
fn upcast_ref<T>(&self) -> &Twhere
T: ObjectType,
Self: IsA<T>,
T
. Read moresource§fn downcast<T>(self) -> Result<T, Self>where
T: ObjectType,
Self: MayDowncastTo<T>,
fn downcast<T>(self) -> Result<T, Self>where
T: ObjectType,
Self: MayDowncastTo<T>,
T
. Read moresource§fn downcast_ref<T>(&self) -> Option<&T>where
T: ObjectType,
Self: MayDowncastTo<T>,
fn downcast_ref<T>(&self) -> Option<&T>where
T: ObjectType,
Self: MayDowncastTo<T>,
T
. Read moresource§fn dynamic_cast<T>(self) -> Result<T, Self>where
T: ObjectType,
fn dynamic_cast<T>(self) -> Result<T, Self>where
T: ObjectType,
T
. This handles upcasting, downcasting
and casting between interface and interface implementors. All checks are performed at
runtime, while upcast
will do many checks at compile-time already. downcast
will
perform the same checks at runtime as dynamic_cast
, but will also ensure some amount of
compile-time safety. Read moresource§fn dynamic_cast_ref<T>(&self) -> Option<&T>where
T: ObjectType,
fn dynamic_cast_ref<T>(&self) -> Option<&T>where
T: ObjectType,
T
. This handles upcasting, downcasting
and casting between interface and interface implementors. All checks are performed at
runtime, while downcast
and upcast
will do many checks at compile-time already. Read moresource§unsafe fn unsafe_cast<T>(self) -> Twhere
T: ObjectType,
unsafe fn unsafe_cast<T>(self) -> Twhere
T: ObjectType,
T
unconditionally. Read moresource§unsafe fn unsafe_cast_ref<T>(&self) -> &Twhere
T: ObjectType,
unsafe fn unsafe_cast_ref<T>(&self) -> &Twhere
T: ObjectType,
&T
unconditionally. Read moresource§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)source§impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
source§impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
source§impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
source§impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
source§impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
source§impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
source§impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
unsafe fn from_glib_none_as_vec(ptr: *const GList) -> Vec<T>
unsafe fn from_glib_container_as_vec(_: *const GList) -> Vec<T>
unsafe fn from_glib_full_as_vec(_: *const GList) -> Vec<T>
source§impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
unsafe fn from_glib_none_as_vec(ptr: *const GPtrArray) -> Vec<T>
unsafe fn from_glib_container_as_vec(_: *const GPtrArray) -> Vec<T>
unsafe fn from_glib_full_as_vec(_: *const GPtrArray) -> Vec<T>
source§impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
unsafe fn from_glib_none_as_vec(ptr: *const GSList) -> Vec<T>
unsafe fn from_glib_container_as_vec(_: *const GSList) -> Vec<T>
unsafe fn from_glib_full_as_vec(_: *const GSList) -> Vec<T>
source§impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
unsafe fn from_glib_none_as_vec(ptr: *mut GList) -> Vec<T>
unsafe fn from_glib_container_as_vec(ptr: *mut GList) -> Vec<T>
unsafe fn from_glib_full_as_vec(ptr: *mut GList) -> Vec<T>
source§impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
unsafe fn from_glib_none_as_vec(ptr: *mut GPtrArray) -> Vec<T>
unsafe fn from_glib_container_as_vec(ptr: *mut GPtrArray) -> Vec<T>
unsafe fn from_glib_full_as_vec(ptr: *mut GPtrArray) -> Vec<T>
source§impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
unsafe fn from_glib_none_as_vec(ptr: *mut GSList) -> Vec<T>
unsafe fn from_glib_container_as_vec(ptr: *mut GSList) -> Vec<T>
unsafe fn from_glib_full_as_vec(ptr: *mut GSList) -> Vec<T>
source§impl<O> GObjectPropertyExpressionExt for O
impl<O> GObjectPropertyExpressionExt for O
source§fn property_expression(&self, property_name: &str) -> PropertyExpression
fn property_expression(&self, property_name: &str) -> PropertyExpression
source§fn property_expression_weak(&self, property_name: &str) -> PropertyExpression
fn property_expression_weak(&self, property_name: &str) -> PropertyExpression
source§fn this_expression(property_name: &str) -> PropertyExpression
fn this_expression(property_name: &str) -> PropertyExpression
this
object.source§impl<T> IntoClosureReturnValue for T
impl<T> IntoClosureReturnValue for T
fn into_closure_return_value(self) -> Option<Value>
source§impl<U> IsSubclassableExt for Uwhere
U: IsClass + ParentClassIs,
impl<U> IsSubclassableExt for Uwhere
U: IsClass + ParentClassIs,
fn parent_class_init<T>(class: &mut Class<U>)
fn parent_instance_init<T>(instance: &mut InitializingObject<T>)
source§impl<T> ObjectExt for Twhere
T: ObjectType,
impl<T> ObjectExt for Twhere
T: ObjectType,
source§fn is<U>(&self) -> boolwhere
U: StaticType,
fn is<U>(&self) -> boolwhere
U: StaticType,
true
if the object is an instance of (can be cast to) T
.source§fn object_class(&self) -> &Class<Object>
fn object_class(&self) -> &Class<Object>
ObjectClass
of the object. Read moresource§fn class_of<U>(&self) -> Option<&Class<U>>where
U: IsClass,
fn class_of<U>(&self) -> Option<&Class<U>>where
U: IsClass,
T
. Read moresource§fn interface<U>(&self) -> Option<InterfaceRef<'_, U>>where
U: IsInterface,
fn interface<U>(&self) -> Option<InterfaceRef<'_, U>>where
U: IsInterface,
T
of the object. Read moresource§fn set_property_from_value(&self, property_name: &str, value: &Value)
fn set_property_from_value(&self, property_name: &str, value: &Value)
source§fn set_properties(&self, property_values: &[(&str, &dyn ToValue)])
fn set_properties(&self, property_values: &[(&str, &dyn ToValue)])
source§fn set_properties_from_value(&self, property_values: &[(&str, Value)])
fn set_properties_from_value(&self, property_values: &[(&str, Value)])
source§fn property<V>(&self, property_name: &str) -> Vwhere
V: for<'b> FromValue<'b> + 'static,
fn property<V>(&self, property_name: &str) -> Vwhere
V: for<'b> FromValue<'b> + 'static,
property_name
of the object and cast it to the type V. Read moresource§fn property_value(&self, property_name: &str) -> Value
fn property_value(&self, property_name: &str) -> Value
property_name
of the object. Read moresource§fn property_type(&self, property_name: &str) -> Option<Type>
fn property_type(&self, property_name: &str) -> Option<Type>
property_name
of this object. Read moresource§fn find_property(&self, property_name: &str) -> Option<ParamSpec>
fn find_property(&self, property_name: &str) -> Option<ParamSpec>
ParamSpec
of the property property_name
of this object.source§fn list_properties(&self) -> PtrSlice<ParamSpec>
fn list_properties(&self) -> PtrSlice<ParamSpec>
ParamSpec
of the properties of this object.source§fn freeze_notify(&self) -> PropertyNotificationFreezeGuard
fn freeze_notify(&self) -> PropertyNotificationFreezeGuard
source§unsafe fn set_qdata<QD>(&self, key: Quark, value: QD)where
QD: 'static,
unsafe fn set_qdata<QD>(&self, key: Quark, value: QD)where
QD: 'static,
key
. Read moresource§unsafe fn qdata<QD>(&self, key: Quark) -> Option<NonNull<QD>>where
QD: 'static,
unsafe fn qdata<QD>(&self, key: Quark) -> Option<NonNull<QD>>where
QD: 'static,
key
. Read moresource§unsafe fn steal_qdata<QD>(&self, key: Quark) -> Option<QD>where
QD: 'static,
unsafe fn steal_qdata<QD>(&self, key: Quark) -> Option<QD>where
QD: 'static,
key
. Read moresource§unsafe fn set_data<QD>(&self, key: &str, value: QD)where
QD: 'static,
unsafe fn set_data<QD>(&self, key: &str, value: QD)where
QD: 'static,
key
. Read moresource§unsafe fn data<QD>(&self, key: &str) -> Option<NonNull<QD>>where
QD: 'static,
unsafe fn data<QD>(&self, key: &str) -> Option<NonNull<QD>>where
QD: 'static,
key
. Read moresource§unsafe fn steal_data<QD>(&self, key: &str) -> Option<QD>where
QD: 'static,
unsafe fn steal_data<QD>(&self, key: &str) -> Option<QD>where
QD: 'static,
key
. Read moresource§fn block_signal(&self, handler_id: &SignalHandlerId)
fn block_signal(&self, handler_id: &SignalHandlerId)
source§fn unblock_signal(&self, handler_id: &SignalHandlerId)
fn unblock_signal(&self, handler_id: &SignalHandlerId)
source§fn stop_signal_emission(&self, signal_id: SignalId, detail: Option<Quark>)
fn stop_signal_emission(&self, signal_id: SignalId, detail: Option<Quark>)
source§fn stop_signal_emission_by_name(&self, signal_name: &str)
fn stop_signal_emission_by_name(&self, signal_name: &str)
source§fn connect<F>(
&self,
signal_name: &str,
after: bool,
callback: F,
) -> SignalHandlerId
fn connect<F>( &self, signal_name: &str, after: bool, callback: F, ) -> SignalHandlerId
signal_name
on this object. Read moresource§fn connect_id<F>(
&self,
signal_id: SignalId,
details: Option<Quark>,
after: bool,
callback: F,
) -> SignalHandlerId
fn connect_id<F>( &self, signal_id: SignalId, details: Option<Quark>, after: bool, callback: F, ) -> SignalHandlerId
signal_id
on this object. Read moresource§fn connect_local<F>(
&self,
signal_name: &str,
after: bool,
callback: F,
) -> SignalHandlerId
fn connect_local<F>( &self, signal_name: &str, after: bool, callback: F, ) -> SignalHandlerId
signal_name
on this object. Read moresource§fn connect_local_id<F>(
&self,
signal_id: SignalId,
details: Option<Quark>,
after: bool,
callback: F,
) -> SignalHandlerId
fn connect_local_id<F>( &self, signal_id: SignalId, details: Option<Quark>, after: bool, callback: F, ) -> SignalHandlerId
signal_id
on this object. Read moresource§unsafe fn connect_unsafe<F>(
&self,
signal_name: &str,
after: bool,
callback: F,
) -> SignalHandlerId
unsafe fn connect_unsafe<F>( &self, signal_name: &str, after: bool, callback: F, ) -> SignalHandlerId
signal_name
on this object. Read moresource§unsafe fn connect_unsafe_id<F>(
&self,
signal_id: SignalId,
details: Option<Quark>,
after: bool,
callback: F,
) -> SignalHandlerId
unsafe fn connect_unsafe_id<F>( &self, signal_id: SignalId, details: Option<Quark>, after: bool, callback: F, ) -> SignalHandlerId
signal_id
on this object. Read moresource§fn connect_closure(
&self,
signal_name: &str,
after: bool,
closure: RustClosure,
) -> SignalHandlerId
fn connect_closure( &self, signal_name: &str, after: bool, closure: RustClosure, ) -> SignalHandlerId
signal_name
on this object. Read moresource§fn connect_closure_id(
&self,
signal_id: SignalId,
details: Option<Quark>,
after: bool,
closure: RustClosure,
) -> SignalHandlerId
fn connect_closure_id( &self, signal_id: SignalId, details: Option<Quark>, after: bool, closure: RustClosure, ) -> SignalHandlerId
signal_id
on this object. Read moresource§fn watch_closure(&self, closure: &impl AsRef<Closure>)
fn watch_closure(&self, closure: &impl AsRef<Closure>)
closure
to the lifetime of the object. When
the object’s reference count drops to zero, the closure will be
invalidated. An invalidated closure will ignore any calls to
invoke_with_values
, or
invoke
when using Rust closures.source§fn emit<R>(&self, signal_id: SignalId, args: &[&dyn ToValue]) -> Rwhere
R: TryFromClosureReturnValue,
fn emit<R>(&self, signal_id: SignalId, args: &[&dyn ToValue]) -> Rwhere
R: TryFromClosureReturnValue,
source§fn emit_with_values(&self, signal_id: SignalId, args: &[Value]) -> Option<Value>
fn emit_with_values(&self, signal_id: SignalId, args: &[Value]) -> Option<Value>
Self::emit
but takes Value
for the arguments.source§fn emit_by_name<R>(&self, signal_name: &str, args: &[&dyn ToValue]) -> Rwhere
R: TryFromClosureReturnValue,
fn emit_by_name<R>(&self, signal_name: &str, args: &[&dyn ToValue]) -> Rwhere
R: TryFromClosureReturnValue,
source§fn emit_by_name_with_values(
&self,
signal_name: &str,
args: &[Value],
) -> Option<Value>
fn emit_by_name_with_values( &self, signal_name: &str, args: &[Value], ) -> Option<Value>
source§fn emit_by_name_with_details<R>(
&self,
signal_name: &str,
details: Quark,
args: &[&dyn ToValue],
) -> Rwhere
R: TryFromClosureReturnValue,
fn emit_by_name_with_details<R>(
&self,
signal_name: &str,
details: Quark,
args: &[&dyn ToValue],
) -> Rwhere
R: TryFromClosureReturnValue,
source§fn emit_by_name_with_details_and_values(
&self,
signal_name: &str,
details: Quark,
args: &[Value],
) -> Option<Value>
fn emit_by_name_with_details_and_values( &self, signal_name: &str, details: Quark, args: &[Value], ) -> Option<Value>
source§fn emit_with_details<R>(
&self,
signal_id: SignalId,
details: Quark,
args: &[&dyn ToValue],
) -> Rwhere
R: TryFromClosureReturnValue,
fn emit_with_details<R>(
&self,
signal_id: SignalId,
details: Quark,
args: &[&dyn ToValue],
) -> Rwhere
R: TryFromClosureReturnValue,
source§fn emit_with_details_and_values(
&self,
signal_id: SignalId,
details: Quark,
args: &[Value],
) -> Option<Value>
fn emit_with_details_and_values( &self, signal_id: SignalId, details: Quark, args: &[Value], ) -> Option<Value>
source§fn disconnect(&self, handler_id: SignalHandlerId)
fn disconnect(&self, handler_id: SignalHandlerId)
source§fn connect_notify<F>(&self, name: Option<&str>, f: F) -> SignalHandlerId
fn connect_notify<F>(&self, name: Option<&str>, f: F) -> SignalHandlerId
notify
signal of the object. Read moresource§fn connect_notify_local<F>(&self, name: Option<&str>, f: F) -> SignalHandlerId
fn connect_notify_local<F>(&self, name: Option<&str>, f: F) -> SignalHandlerId
notify
signal of the object. Read moresource§unsafe fn connect_notify_unsafe<F>(
&self,
name: Option<&str>,
f: F,
) -> SignalHandlerId
unsafe fn connect_notify_unsafe<F>( &self, name: Option<&str>, f: F, ) -> SignalHandlerId
notify
signal of the object. Read more