Enums

Details

class WebKit2.AuthenticationScheme(value)

Bases: GObject.GEnum

Enum values representing the authentication scheme.

New in version 2.2.

DEFAULT = 1

The default authentication scheme of WebKit.

UNKNOWN = 100

Authentication scheme unknown.

HTTP_BASIC = 2

Basic authentication scheme as defined in RFC 2617.

HTTP_DIGEST = 3

Digest authentication scheme as defined in RFC 2617.

HTML_FORM = 4

HTML Form authentication.

NTLM = 5

NTLM Microsoft proprietary authentication scheme.

NEGOTIATE = 6

Negotiate (or SPNEGO) authentication scheme as defined in RFC 4559.

CLIENT_CERTIFICATE_REQUESTED = 7

Client Certificate Authentication (see RFC 2246).

SERVER_TRUST_EVALUATION_REQUESTED = 8

Server Trust Authentication.

CLIENT_CERTIFICATE_PIN_REQUESTED = 9

Client certificate PIN required for use.

New in version 2.34.

class WebKit2.AutomationBrowsingContextPresentation(value)

Bases: GObject.GEnum

Enum values used for determining the automation browsing context presentation.

New in version 2.28.

WINDOW = 0

a window

TAB = 1

a tab

class WebKit2.AutoplayPolicy(value)

Bases: GObject.GEnum

Enum values used to specify autoplay policies.

New in version 2.30.

ALLOW = 0

Do not restrict autoplay.

ALLOW_WITHOUT_SOUND = 1

Allow videos to autoplay if they have no audio track, or if their audio track is muted.

DENY = 2

Never allow autoplay.

class WebKit2.CacheModel(value)

Bases: GObject.GEnum

Enum values used for determining the WebKit2.WebContext cache model.

DOCUMENT_VIEWER = 0

Disable the cache completely, which substantially reduces memory usage. Useful for applications that only access a single local file, with no navigation to other pages. No remote resources will be cached.

WEB_BROWSER = 1

Improve document load speed substantially by caching a very large number of resources and previously viewed content.

DOCUMENT_BROWSER = 2

A cache model optimized for viewing a series of local files – for example, a documentation viewer or a website designer. WebKit will cache a moderate number of resources.

class WebKit2.ContextMenuAction(value)

Bases: GObject.GEnum

Enum values used to denote the stock actions for WebKit2.ContextMenuItem s

NO_ACTION = 0

No action, used by separator menu items.

Open current link.

GO_BACK = 10

Load the previous history item.

CUSTOM = 10000

Custom action defined by applications.

GO_FORWARD = 11

Load the next history item.

STOP = 12

Stop any ongoing loading operation.

RELOAD = 13

Reload the contents of current view.

COPY = 14

Copy current selection the clipboard.

CUT = 15

Cut current selection to the clipboard.

PASTE = 16

Paste clipboard contents.

DELETE = 17

Delete current selection.

SELECT_ALL = 18

Select all text.

INPUT_METHODS = 19

Input methods menu.

Open current link in a new window.

UNICODE = 20

Unicode menu.

SPELLING_GUESS = 21

A proposed replacement for a misspelled word.

NO_GUESSES_FOUND = 22

An indicator that spellchecking found no proposed replacements.

IGNORE_SPELLING = 23

Causes the spellchecker to ignore the word for this session.

LEARN_SPELLING = 24

Causes the spellchecker to add the word to the dictionary.

IGNORE_GRAMMAR = 25

Ignore grammar.

FONT_MENU = 26

Font options menu.

BOLD = 27

Bold.

ITALIC = 28

Italic.

UNDERLINE = 29

Underline.

Download link destination.

OUTLINE = 30

Outline.

INSPECT_ELEMENT = 31

Open current element in the inspector.

OPEN_VIDEO_IN_NEW_WINDOW = 32

Open current video element in a new window.

OPEN_AUDIO_IN_NEW_WINDOW = 33

Open current audio element in a new window.

Copy video link location in to the clipboard.

Copy audio link location in to the clipboard.

TOGGLE_MEDIA_CONTROLS = 36

Enable or disable media controls.

TOGGLE_MEDIA_LOOP = 37

Enable or disable media loop.

ENTER_VIDEO_FULLSCREEN = 38

Show current video element in fullscreen mode.

MEDIA_PLAY = 39

Play current media element.

Copy link location to the clipboard.

MEDIA_PAUSE = 40

Pause current media element.

MEDIA_MUTE = 41

Mute current media element.

DOWNLOAD_VIDEO_TO_DISK = 42

Download video to disk.

New in version 2.2.

DOWNLOAD_AUDIO_TO_DISK = 43

Download audio to disk.

New in version 2.2.

INSERT_EMOJI = 44

Insert an emoji.

New in version 2.26.

PASTE_AS_PLAIN_TEXT = 45

Paste clipboard contents as plain text.

New in version 2.30.

OPEN_IMAGE_IN_NEW_WINDOW = 5

Open current image in a new window.

DOWNLOAD_IMAGE_TO_DISK = 6

Download current image.

COPY_IMAGE_TO_CLIPBOARD = 7

Copy current image to the clipboard.

COPY_IMAGE_URL_TO_CLIPBOARD = 8

Copy current image location to the clipboard.

OPEN_FRAME_IN_NEW_WINDOW = 9

Open current frame in a new window.

class WebKit2.CookieAcceptPolicy(value)

Bases: GObject.GEnum

Enum values used to denote the cookie acceptance policies.

ALWAYS = 0

Accept all cookies unconditionally.

NEVER = 1

Reject all cookies unconditionally.

NO_THIRD_PARTY = 2

Accept only cookies set by the main document loaded.

class WebKit2.CookiePersistentStorage(value)

Bases: GObject.GEnum

Enum values used to denote the cookie persistent storage types.

TEXT = 0

Cookies are stored in a text file in the Mozilla “cookies.txt” format.

SQLITE = 1

Cookies are stored in a SQLite file in the current Mozilla format.

class WebKit2.CredentialPersistence(value)

Bases: GObject.GEnum

Enum values representing the duration for which a credential persists.

New in version 2.2.

NONE = 0

Credential does not persist

FOR_SESSION = 1

Credential persists for session only

PERMANENT = 2

Credential persists permanently

class WebKit2.DownloadError(value)

Bases: GObject.GEnum

Enum values used to denote the various download errors.

classmethod quark()
Returns:

download error domain.

Return type:

int

Gets the quark for the domain of download errors.

CANCELLED_BY_USER = 400

Download was cancelled by user

DESTINATION = 401

Download failure due to destination error

NETWORK = 499

Download failure due to network error

class WebKit2.FaviconDatabaseError(value)

Bases: GObject.GEnum

Enum values used to denote the various errors related to the WebKit2.FaviconDatabase.

classmethod quark()
Returns:

favicon database error domain.

Return type:

int

Gets the quark for the domain of favicon database errors.

NOT_INITIALIZED = 0

The WebKit2.FaviconDatabase is closed

FAVICON_NOT_FOUND = 1

There is not an icon available for the requested URL

FAVICON_UNKNOWN = 2

There might be an icon for the requested URL, but its data is unknown at the moment

class WebKit2.FeatureStatus(value)

Bases: GObject.GEnum

Describes the status of a [struct`WebKitFeature`].

The status for a given feature can be obtained with [id`webkit_feature_get_status`].

New in version 2.42.

EMBEDDER = 0

Feature that adjust behaviour for specific application needs. The feature is not part of a Web platform feature, not a mature feature intended to be always on.

UNSTABLE = 1

Feature in development. The feature may be unfinished, and there are no guarantees about its safety and stability.

INTERNAL = 2

Feature for debugging the WebKit engine. The feature is not generally useful for user or web developers, and always disabled by default.

DEVELOPER = 3

Feature for web developers. The feature is not generally useful for end users, and always disabled by default.

TESTABLE = 4

Feature in active development and complete enough for testing. The feature may not be yet ready to ship and is disabled by default.

PREVIEW = 5

Feature ready to be tested by users. The feature is disabled by default, but may be enabled by applications automatically e.g. in their “technology preview” or “beta” versions.

STABLE = 6

Feature ready for general use. The feature is enabled by default, but it may still be toggled to support debugging and testing.

MATURE = 7

Feature in general use. The feature is always enabled and in general there should be no user-facing interface to toggle it.

class WebKit2.HardwareAccelerationPolicy(value)

Bases: GObject.GEnum

Enum values used for determining the hardware acceleration policy.

New in version 2.16.

ON_DEMAND = 0

Hardware acceleration is enabled/disabled as request by web contents.

ALWAYS = 1

Hardware acceleration is always enabled, even for websites not requesting it.

NEVER = 2

Hardware acceleration is always disabled, even for websites requesting it.

class WebKit2.InputPurpose(value)

Bases: GObject.GEnum

Enum values used to describe the primary purpose of the active editable element.

New in version 2.28.

FREE_FORM = 0

Editable element expects any characters

DIGITS = 1

Editable element expects digits

NUMBER = 2

Editable element expects a number

PHONE = 3

Editable element expects a telephone

URL = 4

Editable element expects a URL

EMAIL = 5

Editable element expects an email

PASSWORD = 6

Editable element expects a password

class WebKit2.InsecureContentEvent(value)

Bases: GObject.GEnum

Enum values used to denote the different events which can trigger the detection of insecure content.

RUN = 0

Insecure content has been detected by trying to execute any kind of logic (e.g. a script) from an untrusted source.

DISPLAYED = 1

Insecure content has been detected by trying to display any kind of resource (e.g. an image) from an untrusted source.

class WebKit2.JavascriptError(value)

Bases: GObject.GEnum

Enum values used to denote errors happening when executing JavaScript

classmethod quark()
Returns:

JavaScript error domain.

Return type:

int

Gets the quark for the domain of JavaScript errors.

INVALID_PARAMETER = 600

An unsupported parameter has been used to call and async function from API.

New in version 2.40.

INVALID_RESULT = 601

The result of JavaScript execution could not be returned.

New in version 2.40.

SCRIPT_FAILED = 699

An exception was raised in JavaScript execution

class WebKit2.LoadEvent(value)

Bases: GObject.GEnum

Enum values used to denote the different events that happen during a WebKit2.WebView load operation.

STARTED = 0

A new load request has been made. No data has been received yet, empty structures have been allocated to perform the load; the load may still fail due to transport issues such as not being able to resolve a name, or connect to a port.

REDIRECTED = 1

A provisional data source received a server redirect.

COMMITTED = 2

The content started arriving for a page load. The necessary transport requirements are established, and the load is being performed.

FINISHED = 3

Load completed. All resources are done loading or there was an error during the load operation.

class WebKit2.MediaCaptureState(value)

Bases: GObject.GEnum

Enum values used to specify the capture state of a media device.

New in version 2.34.

NONE = 0

Media capture is disabled.

ACTIVE = 1

Media capture is active.

MUTED = 2

Media capture is muted.

class WebKit2.NavigationType(value)

Bases: GObject.GEnum

Enum values used to denote the various navigation types.

The navigation was triggered by clicking a link.

FORM_SUBMITTED = 1

The navigation was triggered by submitting a form.

BACK_FORWARD = 2

The navigation was triggered by navigating forward or backward.

RELOAD = 3

The navigation was triggered by reloading.

FORM_RESUBMITTED = 4

The navigation was triggered by resubmitting a form.

OTHER = 5

The navigation was triggered by some other action.

class WebKit2.NetworkError(value)

Bases: GObject.GEnum

Enum values used to denote the various network errors.

classmethod quark()
Returns:

network error domain.

Return type:

int

Gets the quark for the domain of networking errors.

TRANSPORT = 300

Load failure due to transport error

UNKNOWN_PROTOCOL = 301

Load failure due to unknown protocol

CANCELLED = 302

Load failure due to cancellation

FILE_DOES_NOT_EXIST = 303

Load failure due to missing file

FAILED = 399

Generic load failure

class WebKit2.NetworkProxyMode(value)

Bases: GObject.GEnum

Enum values used to set the network proxy mode.

New in version 2.16.

DEFAULT = 0

Use the default proxy of the system.

NO_PROXY = 1

Do not use any proxy.

CUSTOM = 2

Use custom proxy settings.

class WebKit2.PermissionState(value)

Bases: GObject.GEnum

Enum values representing query permission results.

New in version 2.40.

GRANTED = 0

Access to the feature is granted.

DENIED = 1

Access to the feature is denied.

PROMPT = 2

Access to the feature has to be requested via user prompt.

class WebKit2.PluginError(value)

Bases: GObject.GEnum

Enum values used to denote the various plugin and media errors.

classmethod quark()
Returns:

plug-in error domain.

Return type:

int

Gets the quark for the domain of plug-in errors.

CANNOT_FIND_PLUGIN = 200

Load failure due to missing plugin. Deprecated 2.32

CANNOT_LOAD_PLUGIN = 201

Load failure due to inability to load plugin. Deprecated 2.32

JAVA_UNAVAILABLE = 202

Load failure due to missing Java support that is required to load plugin. Deprecated 2.32

CONNECTION_CANCELLED = 203

Load failure due to connection cancellation. Deprecated 2.32

WILL_HANDLE_LOAD = 204

Preliminary load failure for media content types. A new load will be started to perform the media load.

FAILED = 299

Generic plugin load failure. Deprecated 2.32

class WebKit2.PolicyDecisionType(value)

Bases: GObject.GEnum

Enum values used for determining the type of a policy decision during WebKit2.WebView ::decide-policy.

NAVIGATION_ACTION = 0

This type of policy decision is requested when WebKit is about to navigate to a new page in either the main frame or a subframe. Acceptable policy decisions are either WebKit2.PolicyDecision.use() or WebKit2.PolicyDecision.ignore(). This type of policy decision is always a WebKit2.NavigationPolicyDecision.

NEW_WINDOW_ACTION = 1

This type of policy decision is requested when WebKit is about to create a new window. Acceptable policy decisions are either WebKit2.PolicyDecision.use() or WebKit2.PolicyDecision.ignore(). This type of policy decision is always a WebKit2.NavigationPolicyDecision. These decisions are useful for implementing special actions for new windows, such as forcing the new window to open in a tab when a keyboard modifier is active or handling a special target attribute on <a> elements.

RESPONSE = 2

This type of decision is used when WebKit has received a response for a network resource and is about to start the load. Note that these resources include all subresources of a page such as images and stylesheets as well as main documents. Appropriate policy responses to this decision are WebKit2.PolicyDecision.use(), WebKit2.PolicyDecision.ignore(), or WebKit2.PolicyDecision.download(). This type of policy decision is always a WebKit2.ResponsePolicyDecision. This decision is useful for forcing some types of resources to be downloaded rather than rendered in the WebView or to block the transfer of resources entirely.

class WebKit2.PolicyError(value)

Bases: GObject.GEnum

Enum values used to denote the various policy errors.

classmethod quark()
Returns:

policy error domain.

Return type:

int

Gets the quark for the domain of policy errors.

CANNOT_SHOW_MIME_TYPE = 100

Load failure due to unsupported mime type

CANNOT_SHOW_URI = 101

Load failure due to URI that can not be shown

FRAME_LOAD_INTERRUPTED_BY_POLICY_CHANGE = 102

Load failure due to frame load interruption by policy change

CANNOT_USE_RESTRICTED_PORT = 103

Load failure due to port restriction

FAILED = 199

Generic load failure due to policy error

class WebKit2.PrintError(value)

Bases: GObject.GEnum

Enum values used to denote the various print errors.

classmethod quark()
Returns:

print error domain.

Return type:

int

Gets the quark for the domain of printing errors.

PRINTER_NOT_FOUND = 500

Selected printer cannot be found

INVALID_PAGE_RANGE = 501

Invalid page range

GENERAL = 599

Unspecified error during a print operation

class WebKit2.PrintOperationResponse(value)

Bases: GObject.GEnum

Enum values representing the response of the print dialog shown with WebKit2.PrintOperation.run_dialog().

PRINT = 0

Print button was clicked in print dialog

CANCEL = 1

Print dialog was cancelled

class WebKit2.ProcessModel(value)

Bases: GObject.GEnum

Enum values used for determining the WebKit2.WebContext process model.

New in version 2.4.

Deprecated since version 2.40.

SHARED_SECONDARY_PROCESS = 0

Deprecated 2.26.

MULTIPLE_SECONDARY_PROCESSES = 1

Use one process for each WebKit2.WebView, while still allowing for some of them to share a process in certain situations. The main advantage of this process model is that the rendering process for a web view can crash while the rest of the views keep working normally. This process model is indicated for applications which may use a number of web views and the content of in each must not interfere with the rest — for example a full-fledged web browser with support for multiple tabs.

class WebKit2.SaveMode(value)

Bases: GObject.GEnum

Enum values to specify the different ways in which a WebKit2.WebView can save its current web page into a self-contained file.

MHTML = 0

Save the current page using the MHTML format.

class WebKit2.ScriptDialogType(value)

Bases: GObject.GEnum

Enum values used for determining the type of WebKit2.ScriptDialog

ALERT = 0

Alert script dialog, used to show a message to the user.

CONFIRM = 1

Confirm script dialog, used to ask confirmation to the user.

PROMPT = 2

Prompt script dialog, used to ask information to the user.

BEFORE_UNLOAD_CONFIRM = 3

Before unload confirm dialog, used to ask confirmation to leave the current page to the user.

New in version 2.12.

class WebKit2.SnapshotError(value)

Bases: GObject.GEnum

Enum values used to denote errors happening when creating snapshots of WebKit2.WebView

classmethod quark()
Returns:

snapshot error domain.

Return type:

int

Gets the quark for the domain of page snapshot errors.

CREATE = 799

An error occurred when creating a webpage snapshot.

class WebKit2.SnapshotRegion(value)

Bases: GObject.GEnum

Enum values used to specify the region from which to get a WebKit2.WebView snapshot

VISIBLE = 0

Specifies a snapshot only for the area that is visible in the webview

FULL_DOCUMENT = 1

A snapshot of the entire document.

class WebKit2.TLSErrorsPolicy(value)

Bases: GObject.GEnum

Enum values used to denote the TLS errors policy.

IGNORE = 0

Ignore TLS errors.

FAIL = 1

TLS errors will emit WebKit2.WebView ::load-failed-with-tls-errors and, if the signal is handled, finish the load. In case the signal is not handled, WebKit2.WebView ::load-failed is emitted before the load finishes.

class WebKit2.UserContentFilterError(value)

Bases: GObject.GEnum

Errors that can occur while compiling content filters.

New in version 2.24.

classmethod quark()
Returns:

user content filter error domain.

Return type:

int

Gets the quark for the domain of user content filter errors.

INVALID_SOURCE = 0

The JSON source for a content filter is invalid.

NOT_FOUND = 1

The requested content filter could not be found.

class WebKit2.UserContentInjectedFrames(value)

Bases: GObject.GEnum

Specifies in which frames user style sheets are to be inserted in.

New in version 2.6.

ALL_FRAMES = 0

Insert the user style sheet in all the frames loaded by the web view, including nested frames. This is the default.

TOP_FRAME = 1

Insert the user style sheet *only* in the top-level frame loaded by the web view, and *not* in the nested frames.

class WebKit2.UserMessageError(value)

Bases: GObject.GEnum

Enum values used to denote errors happening when sending user messages.

New in version 2.28.

classmethod quark()
Returns:

user message error domain.

Return type:

int

Gets the quark for the domain of user message errors.

MESSAGE = 0

The message was not handled by the receiver.

class WebKit2.UserScriptInjectionTime(value)

Bases: GObject.GEnum

Specifies at which place of documents an user script will be inserted.

New in version 2.6.

START = 0

Insert the code of the user script at the beginning of loaded documents. This is the default.

END = 1

Insert the code of the user script at the end of the loaded documents.

class WebKit2.UserStyleLevel(value)

Bases: GObject.GEnum

Specifies how to treat an user style sheet.

New in version 2.6.

USER = 0

The style sheet is an user style sheet, its contents always override other style sheets. This is the default.

AUTHOR = 1

The style sheet will be treated as if it was provided by the loaded documents. That means other user style sheets may still override it.

class WebKit2.WebExtensionMode(value)

Bases: GObject.GEnum

Enum values used for setting if a WebKit2.WebView is intended for WebExtensions.

New in version 2.38.

NONE = 0

Not for an extension.

MANIFESTV2 = 1

For a ManifestV2 extension.

MANIFESTV3 = 2

For a ManifestV3 extension.

class WebKit2.WebProcessTerminationReason(value)

Bases: GObject.GEnum

Enum values used to specify the reason why the web process terminated abnormally.

New in version 2.20.

CRASHED = 0

the web process crashed.

EXCEEDED_MEMORY_LIMIT = 1

the web process exceeded the memory limit.

TERMINATED_BY_API = 2

the web process termination was requested by an API call.

New in version 2.34.