Web Inspector: Canvas: add support for showing WebGPU contexts
[WebKit-https.git] / Source / WebCore / testing / InternalSettings.idl
1 /*
2  * Copyright (C) 2012 Google Inc. All rights reserved.
3  * Copyright (C) 2015 Apple Inc. All rights reserved.
4  *
5  * Redistribution and use in source and binary forms, with or without
6  * modification, are permitted provided that the following conditions
7  * are met:
8  *
9  * 1.  Redistributions of source code must retain the above copyright
10  *     notice, this list of conditions and the following disclaimer.
11  * 2.  Redistributions in binary form must reproduce the above copyright
12  *     notice, this list of conditions and the following disclaimer in the
13  *     documentation and/or other materials provided with the distribution.
14  *
15  * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
16  * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
17  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
18  * DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY
19  * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
20  * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
21  * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
22  * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25  */
26
27 enum ForcedAccessibilityValue { "system", "on", "off" };
28 enum FrameFlatteningValue { "Disabled", "EnabledForNonFullScreenIFrames", "FullyEnabled" };
29 enum FontLoadTimingOverride { "Block", "Swap", "Failure" };
30
31 [
32     NoInterfaceObject,
33     JSGenerateToJSObject,
34     ExportMacro=WEBCORE_TESTSUPPORT_EXPORT,
35 ] interface InternalSettings : InternalSettingsGenerated {
36     [MayThrowException] void setTouchEventEmulationEnabled(boolean enabled);
37
38     // Fonts, text
39     [MayThrowException] void setStandardFontFamily(DOMString family, DOMString script);
40     [MayThrowException] void setSerifFontFamily(DOMString family, DOMString script);
41     [MayThrowException] void setSansSerifFontFamily(DOMString family, DOMString script);
42     [MayThrowException] void setFixedFontFamily(DOMString family, DOMString script);
43     [MayThrowException] void setCursiveFontFamily(DOMString family, DOMString script);
44     [MayThrowException] void setFantasyFontFamily(DOMString family, DOMString script);
45     [MayThrowException] void setPictographFontFamily(DOMString family, DOMString script);
46     [MayThrowException] void setFontFallbackPrefersPictographs(boolean preferPictographs);
47     [MayThrowException] void setFontLoadTimingOverride(FontLoadTimingOverride override);
48     [MayThrowException] void setShouldIgnoreFontLoadCompletions(boolean ignore);
49
50     [MayThrowException] void setTextAutosizingEnabled(boolean enabled);
51     [MayThrowException] void setTextAutosizingWindowSizeOverride(long width, long height);
52
53     // Media
54     [MayThrowException] void setCanStartMedia(boolean enabled);
55     [Conditional=VIDEO_TRACK, MayThrowException] void setShouldDisplayTrackKind(DOMString kind, boolean enabled);
56     [Conditional=VIDEO_TRACK, MayThrowException] boolean shouldDisplayTrackKind(DOMString trackKind);
57     [MayThrowException] void setDefaultVideoPosterURL(DOMString poster);
58     [MayThrowException] void setTimeWithoutMouseMovementBeforeHidingControls(unrestricted double time);
59     [MayThrowException] void setMediaTypeOverride(DOMString mediaTypeOverride);
60     void setAllowsAirPlayForMediaPlayback(boolean available);
61     [Conditional=MEDIA_STREAM, MayThrowException] void setMediaCaptureRequiresSecureConnection(boolean enable);
62
63     [MayThrowException] void setForcePendingWebGLPolicy(boolean forced);
64
65     [MayThrowException] void setQuickTimePluginReplacementEnabled(boolean enabled);
66     [MayThrowException] void setYouTubeFlashPluginReplacementEnabled(boolean enabled);
67
68     // Editing, forms
69     [MayThrowException] void setEditingBehavior(DOMString behavior);
70     [MayThrowException] void setShouldConvertPositionStyleOnCopy(boolean convertPosition);
71     [MayThrowException] void setPreferMIMETypeForImages(boolean preferMimeTypeForImage);
72
73     // Other switches
74     [MayThrowException] void setUseDarkAppearance(boolean enabled);
75     [MayThrowException] void setStorageBlockingPolicy(DOMString policy);
76     [MayThrowException] void setImagesEnabled(boolean enabled);
77     [MayThrowException] void setPDFImageCachingPolicy(DOMString policy);
78     [MayThrowException] void setUseLegacyBackgroundSizeShorthandBehavior(boolean enabled);
79     [MayThrowException] void setAutoscrollForDragAndDropEnabled(boolean enabled);
80     [MayThrowException] void setBackgroundShouldExtendBeyondPage(boolean hasExtendedBackground);
81     [MayThrowException] void setScrollingTreeIncludesFrames(boolean enabled);
82     [MayThrowException] void setAllowUnclampedScrollPosition(boolean allowUnclamped);
83
84     [MayThrowException] void setMinimumTimerInterval(unrestricted double intervalInSeconds);
85     [MayThrowException] void setAllowsInlineMediaPlayback(boolean allows);
86     [MayThrowException] void setAllowsInlineMediaPlaybackAfterFullscreen(boolean allows);
87     [MayThrowException] void setInlineMediaPlaybackRequiresPlaysInlineAttribute(boolean requires);
88     [MayThrowException] void setFrameFlattening(FrameFlatteningValue frameFlattening);
89     [MayThrowException] void setIncompleteImageBorderEnabled(boolean enabled);
90
91     // RuntimeEnabledFeatures.
92     void setIndexedDBWorkersEnabled(boolean enabled);
93     void setWebGL2Enabled(boolean enabled);
94     void setWebGPUEnabled(boolean enabled);
95     void setWebVREnabled(boolean enabled);
96     void setScreenCaptureEnabled(boolean enabled);
97
98     [MayThrowException] DOMString userInterfaceDirectionPolicy();
99     [MayThrowException] void setUserInterfaceDirectionPolicy(DOMString policy);
100     [MayThrowException] DOMString systemLayoutDirection();
101     [MayThrowException] void setSystemLayoutDirection(DOMString direction);
102
103     [MayThrowException] boolean deferredCSSParserEnabled();
104     [MayThrowException] void setDeferredCSSParserEnabled(boolean enabled);
105
106     [MayThrowException] void setShouldMockBoldSystemFontForAccessibility(boolean shouldMock);
107
108     attribute ForcedAccessibilityValue forcedColorsAreInvertedAccessibilityValue;
109     attribute ForcedAccessibilityValue forcedDisplayIsMonochromeAccessibilityValue;
110     attribute ForcedAccessibilityValue forcedPrefersReducedMotionAccessibilityValue;
111
112     [MayThrowException] void setShouldManageAudioSessionCategory(boolean should);
113     [MayThrowException] void setCustomPasteboardDataEnabled(boolean enabled);
114
115     [EnabledAtRuntime=WebAnimations] boolean webAnimationsCSSIntegrationEnabled();
116
117     [MayThrowException] void setAccessibilityEventsEnabled(boolean enabled);
118 };
119