Example usage for Java android.webkit WebSettings fields, constructors, methods, implement or subclass
The text is from its open source code.
int | LOAD_DEFAULT Default cache usage mode. |
int | LOAD_CACHE_ELSE_NETWORK Use cached resources when they are available, even if they have expired. |
int | LOAD_NO_CACHE Don't use the cache, load from the network. |
int | LOAD_CACHE_ONLY Don't use the network, load from the cache. |
int | MIXED_CONTENT_ALWAYS_ALLOW Used with #setMixedContentMode In this mode, the WebView will allow a secure origin to load content from any other origin, even if that origin is insecure. |
int | MIXED_CONTENT_NEVER_ALLOW Used with #setMixedContentMode In this mode, the WebView will not allow a secure origin to load content from an insecure origin. |
int | MIXED_CONTENT_COMPATIBILITY_MODE Used with #setMixedContentMode In this mode, the WebView will attempt to be compatible with the approach of a modern web browser with regard to mixed content. |
Class> | getClass() Returns the runtime class of this Object . |
String | getDefaultUserAgent(Context context) Returns the default User-Agent used by a WebView. |
boolean | getJavaScriptEnabled() Gets whether JavaScript is enabled. |
String | getUserAgentString() Gets the WebView's user-agent string. |
void | setAllowContentAccess(boolean allow) Enables or disables content URL access within WebView. |
void | setAllowFileAccess(boolean allow) Enables or disables file access within WebView. |
void | setAllowFileAccessFromFileURLs(boolean flag) Sets whether JavaScript running in the context of a file scheme URL should be allowed to access content from other file scheme URLs. |
void | setAllowUniversalAccessFromFileURLs(boolean flag) Sets whether JavaScript running in the context of a file scheme URL should be allowed to access content from any origin. |
void | setAppCacheEnabled(boolean flag) Sets whether the Application Caches API should be enabled. |
void | setAppCacheMaxSize(long appCacheMaxSize) Sets the maximum size for the Application Cache content. |
void | setAppCachePath(String appCachePath) Sets the path to the Application Caches files. |
void | setBlockNetworkImage(boolean flag) Sets whether the WebView should not load image resources from the network (resources accessed via http and https URI schemes). |
void | setBuiltInZoomControls(boolean enabled) Sets whether the WebView should use its built-in zoom mechanisms. |
void | setCacheMode(@CacheMode int mode) Overrides the way the cache is used. |
void | setDatabaseEnabled(boolean flag) Sets whether the database storage API is enabled. |
void | setDatabasePath(String databasePath) Sets the path to where database storage API databases should be saved. |
void | setDefaultFontSize(int size) Sets the default font size. |
void | setDefaultTextEncodingName(String encoding) Sets the default text encoding name to use when decoding html pages. |
void | setDefaultZoom(ZoomDensity zoom) Sets the default zoom density of the page. |
void | setDisplayZoomControls(boolean enabled) Sets whether the WebView should display on-screen zoom controls when using the built-in zoom mechanisms. |
void | setDomStorageEnabled(boolean flag) Sets whether the DOM storage API is enabled. |
void | setEnableSmoothTransition(boolean enable) Sets whether the WebView will enable smooth transition while panning or zooming or while the window hosting the WebView does not have focus. |
void | setGeolocationDatabasePath(String databasePath) Sets the path where the Geolocation databases should be saved. |
void | setGeolocationEnabled(boolean flag) Sets whether Geolocation is enabled. |
void | setJavaScriptCanOpenWindowsAutomatically(boolean flag) Tells JavaScript to open windows automatically. |
void | setJavaScriptEnabled(boolean flag) Tells the WebView to enable JavaScript execution. |
void | setLayoutAlgorithm(LayoutAlgorithm l) Sets the underlying layout algorithm. |
void | setLightTouchEnabled(boolean enabled) Enables using light touches to make a selection and activate mouseovers. |
void | setLoadsImagesAutomatically(boolean flag) Sets whether the WebView should load image resources. |
void | setLoadWithOverviewMode(boolean overview) Sets whether the WebView loads pages in overview mode, that is, zooms out the content to fit on screen by width. |
void | setMediaPlaybackRequiresUserGesture(boolean require) Sets whether the WebView requires a user gesture to play media. |
void | setMinimumFontSize(int size) Sets the minimum font size. |
void | setMinimumLogicalFontSize(int size) Sets the minimum logical font size. |
void | setMixedContentMode(int mode) Configures the WebView's behavior when a secure origin attempts to load a resource from an insecure origin. |
void | setNavDump(boolean enabled) Enables dumping the pages navigation cache to a text file. |
void | setNeedInitialFocus(boolean flag) Tells the WebView whether it needs to set a node to have focus when WebView#requestFocus(int,android.graphics.Rect) is called. |
void | setPluginsEnabled(boolean flag) Sets whether the WebView should enable plugins. |
void | setPluginState(PluginState state) Tells the WebView to enable, disable, or have plugins on demand. |
void | setRenderPriority(RenderPriority priority) Sets the priority of the Render thread. |
void | setSaveFormData(boolean save) Sets whether the WebView should save form data. |
void | setSavePassword(boolean save) Sets whether the WebView should save passwords. |
void | setSupportMultipleWindows(boolean support) Sets whether the WebView whether supports multiple windows. |
void | setSupportZoom(boolean support) Sets whether the WebView should support zooming using its on-screen zoom controls and gestures. |
void | setTextSize(TextSize t) Sets the text size of the page. |
void | setTextZoom(int textZoom) Sets the text zoom of the page in percent. |
void | setUserAgentString(@Nullable String ua) Sets the WebView's user-agent string. |
void | setUseWideViewPort(boolean use) Sets whether the WebView should enable support for the "viewport" HTML meta tag or should use a wide viewport. |
boolean | supportZoom() Gets whether the WebView supports zoom. |