Объект BrowserWindowConstructorOptions расширяет `BaseWindowConstructorOptions` | Electron
https://www.electronjs.org/ru/docs/latest/api/structures/browser-window-options • 64 KB fetched
Open original page
Объект BrowserWindowConstructorOptions расширяет `BaseWindowConstructorOptions` | Electron
Перейти к основному содержанию
Electron Документация API Блог Инструменты
* Electron Forge
* Electron Fiddle
Сообщество
* Управление
* Примеры
* Ресурсы
Релизы Русский
* English
* Deutsch
* Español
* Français
* 日本語
* Português
* Русский
* 中文
Поиск
* Модули основного процесса
* Модули графического процесса
* Utility Process Modules
* Пользовательские DOM-элементы
* Chromium и Node.js
* Классы
* Структуры API
* BaseWindowConstructorOptions Object
* Объект BluetoothDevice
* Объект BrowserWindowConstructorOptions расширяет `BaseWindowConstructorOptions`
* Объект Certificate
* Объект CertificatePrincipal
* ColorSpace Object
* Объект Cookie
* Объект CPUUsage
* Объект CrashReport
* Объект CustomScheme
* Объект DesktopCapturerSource
* Объект Display
* Object расширений
* Объект ExtensionInfo
* Объект FileFilter
* FilePathWithHeaders Object
* FilesystemPermissionRequest Object extends `PermissionRequest`
* Объект GPUFeatureStatus
* HIDDevice Object
* InputEvent Object
* IpcMainEvent Object extends `Event`
* Объект IpcMainInvokeEvent расширяет `Event`
* IpcRendererEvent Object extends `Event`
* Объект JumpListCategory
* Объект JumpListItem
* Объект KeyboardEvent
* KeyboardInputEvent Object extends `InputEvent`
* MediaAccessPermissionRequest Object extends `PermissionRequest`
* Объект MemoryInfo
* Объект MemoryUsageDetails
* Объект MimeTypedBuffer
* MouseInputEvent Object extends `InputEvent`
* MouseWheelInputEvent Object extends `MouseInputEvent`
* NavigationEntry Object
* Объект NotificationAction
* Объект уведомления
* OffscreenSharedTexture Object
* OpenExternalPermissionRequest Object extends `PermissionRequest`
* PaymentDiscount Object
* PermissionRequest Object
* Объект Point
* Объект PostBody
* Объект PrinterInfo
* Объект ProcessMemoryInfo
* Объект ProcessMetric
* Объект Product
* ProductDiscount Object
* ProductSubscriptionPeriod Object
* Объект ProtocolRequest
* Объект ProtocolResponse
* Объект ProtocolResponseUploadData
* ProxyConfig Object
* Объект Rectangle
* Объект Referrer
* RenderProcessGoneDetails Object
* ResolvedEndpoint Object
* ResolvedHost Object
* Объект ScrubberItem
* Объект SegmentedControlSegment
* Объект SerialPort
* Объект ServiceWorkerInfo
* Объект SharedWorkerInfo
* SharingItem Object
* Объект ShortcutDetails
* Объект Size
* Объект Task
* Объект ThumbarButton
* Объект TraceCategoriesAndOptions
* Объект TraceConfig
* Объект Transaction
* Объект UploadData
* Объект UploadFile
* Объект UploadRawData
* Объект USBDevice
* UserDefaultTypes Object
* WebPreferences Object
* WebRequestFilter Object
* Объект WebSource
* WindowOpenHandlerResponse Object
* SharedDictionaryInfo Object
* SharedDictionaryUsageInfo Object
*
* Структуры API
* Объект BrowserWindowConstructorOptions расширяет `BaseWindowConstructorOptions` Объект BrowserWindowConstructorOptions расширяет BaseWindowConstructorOptions
* webPreferences WebPreferences (опционально) - Настройки функций веб-страницы.
* devTools boolean (опционально) - включает инструменты разработчика. Если значение false , нельзя будет использовать BrowserWindow.webContents.openDevTools() , чтобы открыть инструменты разработчика. По умолчанию - true .
* nodeIntegration boolean (optional) - Whether node integration is enabled. По умолчанию - false .
* nodeIntegrationInWorker boolean (опционально) - включает интеграцию NodeJS в веб-воркерах. По умолчанию - false . More about this can be found in Multithreading .
* nodeIntegrationInSubFrames boolean (опционально) - экспериментальная опция для включения поддержки NodeJS в подфреймах, таких как iframes и дочерних окнах. Все Ваши предварительные загрузки будут загружены для каждого iframe, Вы можете использовать process.isMainFrame , чтобы определить в главном фрейме Вы или нет.
* preload string (опционально) - Определяет скрипт, который будет загружен до других скриптов загружаемых в странице. Этот скрипт будет всегда иметь доступ к API NodeJS, вне зависимости включена или выключена интеграция NodeJS. Значение должно быть абсолютным путем к файлу скрипта. Когда интеграция NodeJS отключена, предварительно загруженный скрипт может повторно ввести глобальные символы NodeJS в глобальную область. See example here .
* sandbox boolean (опционально) - если установлено true, то в окне будет запущена песочница, что делает ее совместимой с песочницей Chromium на уровне операционной системы, и отключает движок NodeJS. Это не тоже самое, что параметр nodeIntegration , доступные API для предзагруженных скриптов более ограничены. Default is true since Electron 20. The sandbox will automatically be disabled when nodeIntegration is set to true . Read more about the option here .
* session Session (optional) - Sets the session used by the page. Вместо передачи экземпляр Session напрямую, вместо этого Вы можете также выбрать использование опции partition , которая принимает строку раздела. Когда оба session и partition определены, session будет предпочтительней. По умолчанию используется сессия по умолчанию.
* partition string (опционально) - устанавливает сессию, используемую на странице в соответствии со строкой раздела сессии. Если partition начинается с persist: , страница будет использовать постоянную сессию, которая доступна всем страницам в приложении с тем же разделом . Если нет префикса persist: , страница будет использовать сессию в памяти. При присваивании одинакового раздела , разные страницы могут иметь одинаковую сессию. По умолчанию используется сессия по умолчанию.
* zoomFactor number (optional) - The default zoom factor of the page, 3.0 represents 300% . По умолчанию 1.0 .
* javascript boolean (optional) - Enables JavaScript support. По умолчанию - true .
* webSecurity boolean (optional) - When false , it will disable the same-origin policy (usually using testing websites by people), and set allowRunningInsecureContent to true if this option has not been set by user. По умолчанию - true .
* allowRunningInsecureContent boolean (optional) - Allow an https page to run JavaScript, CSS or plugins from http URLs. По умолчанию - false .
* images boolean (optional) - Enables image support. По умолчанию - true .
* imageAnimationPolicy string (optional) - Specifies how to run image animations (E.g. GIFs). Can be animate , animateOnce or noAnimation . По умолчанию animate .
* textAreasAreResizable boolean (optional) - Make TextArea elements resizable. Default is true .
* webgl boolean (optional) - Enables WebGL support. По умолчанию - true .
* plugins boolean (optional) - Whether plugins should be enabled. По умолчанию - false .
* experimentalFeatures boolean (optional) - Enables Chromium's experimental features. По умолчанию - false .
* scrollBounce boolean (optional) macOS - Enables scroll bounce (rubber banding) effect on macOS. По умолчанию - false .
* enableBlinkFeatures string (опционально) - список строк функций, разделенных запятой , которые нужно включить, например CSSVariables,KeyboardEventKey . Полный список поддерживаемых возможностей можно найти в файле RuntimeEnabledFeatures.json5 .
* disableBlinkFeatures string (опционально) - Список функциональных возможностей для выключения, разделяются ',' , например CSSVariables,KeyboardEventKey . Полный список поддерживаемых возможностей можно найти в файле RuntimeEnabledFeatures.json5 .
* defaultFontFamily Object (optional) - Sets the default font for the font-family.
* standard string (опционально) - По умолчанию Times New Roman .
* serif string (опционально) - по умолчанию Times New Roman .
* sansSerif string (опционально) - По умолчанию Arial .
* monospace string (опционально) - По умолчанию Courier New .
* cursive string (опционально) - По умолчанию Script .
* fantasy string (опционально) - По умолчанию Impact .
* math string (опционально) - По умолчанию Latin Modern Math .
* defaultFontSize Integer (опционально) - По умолчанию 16 .
* defaultMonospaceFontSize Integer (опционально) - По умолчанию 13 .
* minimumFontSize Integer (опционально) - По умолчанию 0 .
* defaultEncoding string (опционально) - По умолчанию ISO-8859-1 .
* backgroundThrottling boolean (опционально) - Отключать ли анимацию и таймеры, когда страница становится фоновой. Влияет на API видимости страницы . When at least one webContents displayed in a single browserWindow has disabled backgroundThrottling then frames will be drawn and swapped for the whole window and other webContents displayed by it. По умолчанию true .
* offscreen Object | boolean (опционально) - рендеринг окна браузера вне экрана. По умолчанию false . See the offscreen rendering tutorial for more details.
* useSharedTexture boolean (опционально) Экспериментальный - использование GPU общих текстур для ускорения отрисовки. По умолчанию false . See the offscreen rendering tutorial for more details.
* sharedTexturePixelFormat string (optional) Experimental - The requested output format of the shared texture. По умолчанию argb . The name is originated from Chromium media::VideoPixelFormat enum suffix and only subset of them are supported. The actual output pixel format and color space of the texture should refer to OffscreenSharedTexture object in the paint event.
* argb - The requested output texture format is 8-bit unorm RGBA, with SRGB SDR color space.
* rgbaf16 - The requested output texture format is 16-bit float RGBA, with scRGB HDR color space.
* nv12 - The requested output texture format is 12bpp with Y plane followed by a 2x2 interleaved UV plane, with REC709 color space.
* deviceScaleFactor number (optional) Experimental - The device scale factor of the offscreen rendering output. If not set, will use 1 as default.
* contextIsolation boolean (опционально) - Запускать или нет API Electron и определенный скрипт preload в отдельном JavaScript-контексте. По умолчанию true . The context that the preload script runs in will only have access to its own dedicated document and window globals, as well as its own set of JavaScript builtins ( Array , Object , JSON , etc.), which are all invisible to the loaded content. The Electron API will only be available in the preload script and not the loaded page. This option should be used when loading potentially untrusted remote content to ensure the loaded content cannot tamper with the preload script and any Electron APIs being used. This option uses the same technique used by Chrome Content Scripts . You can access this context in the dev tools by selecting the 'Electron Isolated Context' entry in the combo box at the top of the Console tab.
* webviewTag boolean (optional) - Whether to enable the <webview> tag . По умолчанию false . Примечание: Cкрипт preload , настроенный для <webview> , при запуске будет иметь интеграцию NodeJS, так что Вы должны убедиться, что удаленный/непроверенный контент не сможет создавать тег <webview> с возможно вредоносным скриптом preload . You can use the will-attach-webview event on webContents to strip away the preload script and to validate or alter the <webview> 's initial settings.
* additionalArguments string[] (optional) - A list of strings that will be appended to process.argv in the renderer process of this app. Useful for passing small bits of data down to renderer process preload scripts.
* safeDialogs boolean (optional) - Whether to enable browser style consecutive dialog protection. По умолчанию - false .
* safeDialogsMessage string (опционально) - Сообщение, которое будет отображено, когда сработает последовательная защита диалогов. Если не определено, будет использовано сообщение по умолчанию, обратите внимание, что текущее сообщение по умолчанию на английском и не переведено.
* disableDialogs boolean (optional) - Whether to disable dialogs completely. Overrides safeDialogs . По умолчанию - false .
* navigateOnDragDrop boolean (optional) - Whether dragging and dropping a file or link onto the page causes a navigation. По умолчанию - false .
* autoplayPolicy string (опционально) - политика автовоспроизведения для применения к содержимому в окне, может быть no-user-gesture-required , user-gesture-required или document-user-activation-required . По умолчанию no-user-gesture-required .
* disableHtmlFullscreenWindowResize boolean (optional) - Whether to prevent the window from resizing when entering HTML Fullscreen. Default is false .
* accessibleTitle string (optional) - An alternative title string provided only to accessibility tools such as screen readers. This string is not directly visible to users.
* spellcheck boolean (optional) - Whether to enable the builtin spellchecker. По умолчанию - true .
* enableWebSQL boolean (optional) - Whether to enable the WebSQL api . По умолчанию - true .
* v8CacheOptions string (optional) - Enforces the v8 code caching policy used by blink. Accepted values are
* none - Disables code caching
* code - Heuristic based code caching
* bypassHeatCheck - Bypass code caching heuristics but with lazy compilation
* bypassHeatCheckAndEagerCompile - Same as above except compilation is eager. Default policy is code .
* enablePreferredSizeMode boolean (optional) - Whether to enable preferred size mode. The preferred size is the minimum size needed to contain the layout of the document—without requiring scrolling. Enabling this will cause the preferred-size-changed event to be emitted on the WebContents when the preferred size changes. По умолчанию - false .
* transparent boolean (optional) - Whether to enable background transparency for the guest page. По умолчанию - true . Note: The guest page's text and background colors are derived from the color scheme of its root element. When transparency is enabled, the text color will still change accordingly but the background will remain transparent.
* enableDeprecatedPaste boolean (optional) Deprecated - Whether to enable the paste execCommand . По умолчанию - false .
* focusOnNavigation boolean (optional) - Whether to focus the WebContents when navigating. По умолчанию - true .
* paintWhenInitiallyHidden boolean (опционально) - Должен ли рендерер быть активным, когда show равен false и он только что создан. Для document.visibilityState для корректной работы при первой загрузке с show: false необходимо установить значение false . Установка этого в false приведёт к тому, что события ready-to-show не будут запускаться. По умолчанию - true .
Редактировать эту страницу
Назад
Объект BluetoothDevice
Далее
Объект Certificate
Документация
* Начало работы
* Справка по API
Контрольные списки
* Характеристика
* Безопасность
Инструменты
* Electron Forge
* Electron Fiddle
Сообщество
* Управление
* Ресурсы
* Discord
* Bluesky
* X
* Mastodon
* Stack Overflow
Подробнее
* GitHub
* Open Collective
* Панель управления инфраструктурой
Авторское право OpenJS Foundation и участники проекта Electron. Все права защищены. OpenJS Foundation обладает зарегистрированными товарными знаками и использует их. Список товарных знаков OpenJS Foundation приведён в нашей Политике в отношении товарных знаков и в Списке товарных знаков . Товарные знаки™ и логотипы®, не указанные в списке товарных знаков OpenJS Foundation , являются товарными знаками™ или зарегистрированными® товарными знаками их владельцев. Их использование не подразумевает какой-либо принадлежности к ним или поддержки с их стороны. The OpenJS Foundation | Условия использования | Политика конфиденциальности | Устав | Кодекс поведения | Политика в отношении товарных знаков | Список товарных знаков | Политика использования файлов cookie
Hosting and infrastructure graciously provided by
Links found on this page
- Перейти к основному содержанию [direct]
- Electron [direct]
- Документация [direct]
- API [direct]
- Блог [direct]
- Electron Forge [direct]
- Electron Fiddle [direct]
- Управление [direct]
- Примеры [direct]
- Ресурсы [direct]
- Релизы [direct]
- English [direct]
- Deutsch [direct]
- Español [direct]
- Français [direct]
- 日本語 [direct]
- Português [direct]
- 中文 [direct]
- Модули графического процесса [direct]
- Utility Process Modules [direct]
- Пользовательские DOM-элементы [direct]
- Chromium и Node.js [direct]
- Классы [direct]
- Структуры API [direct]
- Объект BluetoothDevice [direct]
- Объект Certificate [direct]
- Объект CertificatePrincipal [direct]
- ColorSpace Object [direct]
- Объект Cookie [direct]
- Объект CPUUsage [direct]
- Объект CrashReport [direct]
- Объект CustomScheme [direct]
- Объект DesktopCapturerSource [direct]
- Объект Display [direct]
- Object расширений [direct]
- Объект ExtensionInfo [direct]
- Объект FileFilter [direct]
- FilePathWithHeaders Object [direct]
- FilesystemPermissionRequest Object extends `PermissionRequest` [direct]
- Объект GPUFeatureStatus [direct]
- HIDDevice Object [direct]
- InputEvent Object [direct]
- IpcMainEvent Object extends `Event` [direct]
- Объект IpcMainInvokeEvent расширяет `Event` [direct]
- IpcRendererEvent Object extends `Event` [direct]
- Объект JumpListCategory [direct]
- Объект JumpListItem [direct]
- Объект KeyboardEvent [direct]
- KeyboardInputEvent Object extends `InputEvent` [direct]
- MediaAccessPermissionRequest Object extends `PermissionRequest` [direct]
- Объект MemoryInfo [direct]
- Объект MemoryUsageDetails [direct]
- Объект MimeTypedBuffer [direct]
- MouseInputEvent Object extends `InputEvent` [direct]
- MouseWheelInputEvent Object extends `MouseInputEvent` [direct]
- NavigationEntry Object [direct]
- Объект NotificationAction [direct]
- Объект уведомления [direct]
- OffscreenSharedTexture Object [direct]
- OpenExternalPermissionRequest Object extends `PermissionRequest` [direct]
- PaymentDiscount Object [direct]
- PermissionRequest Object [direct]
- Объект Point [direct]
- Объект PostBody [direct]
- Объект PrinterInfo [direct]
- Объект ProcessMemoryInfo [direct]
- Объект ProcessMetric [direct]
- Объект Product [direct]
- ProductDiscount Object [direct]
- ProductSubscriptionPeriod Object [direct]
- Объект ProtocolRequest [direct]
- Объект ProtocolResponse [direct]
- Объект ProtocolResponseUploadData [direct]
- ProxyConfig Object [direct]
- Объект Rectangle [direct]
- Объект Referrer [direct]
- RenderProcessGoneDetails Object [direct]
- ResolvedEndpoint Object [direct]
- ResolvedHost Object [direct]
- Объект ScrubberItem [direct]