// Copyright © 2016 The CefSharp Authors. All rights reserved. // // Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. using System; namespace CefSharp { /// /// Interface representing browser initialization settings. /// public interface IBrowserSettings : IDisposable { /// /// StandardFontFamily /// string StandardFontFamily { get; set; } /// /// FixedFontFamily /// string FixedFontFamily { get; set; } /// /// SerifFontFamily /// string SerifFontFamily { get; set; } /// /// SansSerifFontFamily /// string SansSerifFontFamily { get; set; } /// /// CursiveFontFamily /// string CursiveFontFamily { get; set; } /// /// FantasyFontFamily /// string FantasyFontFamily { get; set; } /// /// DefaultFontSize /// int DefaultFontSize { get; set; } /// /// DefaultFixedFontSize /// int DefaultFixedFontSize { get; set; } /// /// MinimumFontSize /// int MinimumFontSize { get; set; } /// /// MinimumLogicalFontSize /// int MinimumLogicalFontSize { get; set; } /// /// Default encoding for Web content. If empty "ISO-8859-1" will be used. Also /// configurable using the "default-encoding" command-line switch. /// string DefaultEncoding { get; set; } /// /// Controls the loading of fonts from remote sources. Also configurable using /// the "disable-remote-fonts" command-line switch. /// CefState RemoteFonts { get; set; } /// /// Controls whether JavaScript can be executed. (Used to Enable/Disable javascript) /// Also configurable using the "disable-javascript" command-line switch. /// CefState Javascript { get; set; } /// /// Controls whether JavaScript can be used to close windows that were not /// opened via JavaScript. JavaScript can still be used to close windows that /// were opened via JavaScript. Also configurable using the /// "disable-javascript-close-windows" command-line switch. /// CefState JavascriptCloseWindows { get; set; } /// /// Controls whether JavaScript can access the clipboard. Also configurable /// using the "disable-javascript-access-clipboard" command-line switch. /// CefState JavascriptAccessClipboard { get; set; } /// /// Controls whether DOM pasting is supported in the editor via /// execCommand("paste"). The |javascript_access_clipboard| setting must also /// be enabled. Also configurable using the "disable-javascript-dom-paste" /// command-line switch. /// CefState JavascriptDomPaste { get; set; } /// /// Controls whether image URLs will be loaded from the network. A cached image /// will still be rendered if requested. Also configurable using the /// "disable-image-loading" command-line switch. /// CefState ImageLoading { get; set; } /// /// Controls whether standalone images will be shrunk to fit the page. Also /// configurable using the "image-shrink-standalone-to-fit" command-line /// switch. /// CefState ImageShrinkStandaloneToFit { get; set; } /// /// Controls whether text areas can be resized. Also configurable using the /// "disable-text-area-resize" command-line switch. /// CefState TextAreaResize { get; set; } /// /// Controls whether the tab key can advance focus to links. Also configurable /// using the "disable-tab-to-links" command-line switch. /// CefState TabToLinks { get; set; } /// /// Controls whether local storage can be used. Also configurable using the /// "disable-local-storage" command-line switch. /// CefState LocalStorage { get; set; } /// /// Controls whether databases can be used. Also configurable using the /// "disable-databases" command-line switch. /// CefState Databases { get; set; } /// /// Controls whether WebGL can be used. Note that WebGL requires hardware /// support and may not work on all systems even when enabled. Also /// configurable using the "disable-webgl" command-line switch. /// CefState WebGl { get; set; } /// /// Opaque background color used for the browser before a document is loaded /// and when no document color is specified. By default the background color /// will be the same as CefSettings.BackgroundColor. Only the RGB compontents /// of the specified value will be used. The alpha component must greater than /// 0 to enable use of the background color but will be otherwise ignored. /// uint BackgroundColor { get; set; } /// /// The maximum rate in frames per second (fps) that CefRenderHandler::OnPaint /// will be called for a windowless browser. The actual fps may be lower if /// the browser cannot generate frames at the requested rate. The minimum /// value is 1 and the maximum value is 60 (default 30). This value can also be /// changed dynamically via IBrowserHost.SetWindowlessFrameRate. /// int WindowlessFrameRate { get; set; } /// /// Gets a value indicating if the browser settings has been disposed. /// bool IsDisposed { get; } /// /// Gets a value indicating if the browser settings instance was created internally by CefSharp. /// Instances created by CefSharp will be Disposed of after use. To control the lifespan yourself /// create an set BrowserSettings yourself. /// bool AutoDispose { get; } /// /// Used internally to get the underlying instance. /// Unlikely you'll use this yourself. /// /// the inner most instance [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] IBrowserSettings UnWrap(); } }