webkit.feature

Module for [Feature] class

class Feature

Types 1

Describes a web engine feature that may be toggled at runtime.

The WebKit web engine includes a set of features which may be toggled programmatically, each one represented by a #WebKitFeature that provides information about it:

  • A unique “identifier”: [webkit.feature.Feature.getIdentifier].
  • A “default value”, which indicates whether the option is enabled

automatically: [webkit.feature.Feature.getDefaultValue].

  • Its “status”, which determines whether it should be considered

user-settable and its development stage (see enum@FeatureStatus for details): [webkit.feature.Feature.getStatus].

  • A category, which may be used to group features together:

[webkit.feature.Feature.getCategory].

  • An optional short “name” which can be presented to an user:

[webkit.feature.Feature.getName].

  • An optional longer “detailed” description:

[webkit.feature.Feature.getDetails].

The lists of available features can be obtained with [webkit.settings.Settings.getAllFeatures], [webkit.settings.Settings.getExperimentalFeatures], and [webkit.settings.Settings.getDevelopmentFeatures]). As a rule of thumb, applications which may want to allow users (i.e. web developers) to test WebKit features should use the list of experimental features. Additionally, applications might want to expose development features *when targeting technically inclined users* for early testing of in-development features (i.e. in “technology preview” or “canary” builds).

Applications must not expose the list of all features to end users because they often lack descriptions and control parts of the web engine which are either intended to be used during development of WebKit itself, or in specific scenarios to tweak how WebKit integrates with the application.

Methods
void * _cPtr(Flag!"Dup" dup = No.Dup)
GType _gType() @property
Feature self()Returns `this`, for use in `with` statements.
string getCategory()Gets the category of the feature.
bool getDefaultValue()Gets whether the feature is enabled by default.
string getDetails()Gets a description for the feature.
string getIdentifier()Gets a string that uniquely identifies the feature. Returns: The identifier string for the feature.
string getName()Gets a short name for the feature.
webkit.types.FeatureStatus getStatus()Gets the status of the feature. Returns: Feature status.
Constructors
this(void * ptr, Flag!"Take" take)