Optional
accentThe accent color for the window. By default, follows user preference in System
Settings. Set to false
to explicitly disable, or set the color in Hex, RGB,
RGBA, HSL, HSLA or named CSS color format. Alpha values will be ignored.
Optional
acceptWhether clicking an inactive window will also click through to the web contents.
Default is false
on macOS. This option is not configurable on other platforms.
Optional
alwaysWhether the window should always stay on top of other windows. Default is
false
.
Optional
autoAuto hide the menu bar unless the Alt
key is pressed. Default is false
.
Optional
backgroundThe window's background color in Hex, RGB, RGBA, HSL, HSLA or named CSS color
format. Alpha in #AARRGGBB format is supported if transparent
is set to
true
. Default is #FFF
(white). See win.setBackgroundColor for more
information.
Optional
backgroundSet the window's system-drawn background material, including behind the
non-client area. Can be auto
, none
, mica
, acrylic
or tabbed
. See
win.setBackgroundMaterial for more information.
Optional
centerShow window in the center of the screen. Default is false
.
Optional
closableWhether window is closable. This is not implemented on Linux. Default is true
.
Optional
darkForces using dark theme for the window, only works on some GTK+3 desktop
environments. Default is false
.
Optional
disableWhether to hide cursor when typing. Default is false
.
Optional
enableEnable the window to be resized larger than screen. Only relevant for macOS, as
other OSes allow larger-than-screen windows by default. Default is false
.
Optional
focusableWhether the window can be focused. Default is true
. On Windows setting
focusable: false
also implies setting skipTaskbar: true
. On Linux setting
focusable: false
makes the window stop interacting with wm, so the window will
always stay on top in all workspaces.
Optional
frameSpecify false
to create a frameless window. Default is true
.
Optional
fullscreenWhether the window should show in fullscreen. When explicitly set to false
the
fullscreen button will be hidden or disabled on macOS. Default is false
.
Optional
fullscreenableWhether the window can be put into fullscreen mode. On macOS, also whether the
maximize/zoom button should toggle full screen mode or maximize window. Default
is true
.
Optional
hasWhether window should have a shadow. Default is true
.
Optional
heightWindow's height in pixels. Default is 600
.
Optional
hiddenWhether window should be hidden when the user toggles into mission control.
Optional
iconThe window icon. On Windows it is recommended to use ICO
icons to get best
visual effects, you can also leave it undefined so the executable's icon will be
used.
Optional
isOptional
isOptional
kioskWhether the window is in kiosk mode. Default is false
.
Optional
maxWindow's maximum height. Default is no limit.
Optional
maximizableWhether window is maximizable. This is not implemented on Linux. Default is
true
.
Optional
maxWindow's maximum width. Default is no limit.
Optional
minWindow's minimum height. Default is 0
.
Optional
minimizableWhether window is minimizable. This is not implemented on Linux. Default is
true
.
Optional
minWindow's minimum width. Default is 0
.
Optional
modalWhether this is a modal window. This only works when the window is a child
window. Default is false
.
Optional
movableWhether window is movable. This is not implemented on Linux. Default is true
.
Optional
opacitySet the initial opacity of the window, between 0.0 (fully transparent) and 1.0 (fully opaque). This is only implemented on Windows and macOS.
Optional
paintWhether the renderer should be active when show
is false
and it has just
been created. In order for document.visibilityState
to work correctly on
first load with show: false
you should set this to false
. Setting this to
false
will cause the ready-to-show
event to not fire. Default is true
.
Optional
parentSpecify parent window. Default is null
.
Optional
preventBy default, the window will be shown as soon as the content is ready to render.
This can be prevented by handing over preventAutomaticShow: true
.
Use this for fine-grained control over when to show the window, e.g. to coordinate with a splash screen.
Optional
resizableWhether window is resizable. Default is true
.
Optional
roundedWhether frameless window should have rounded corners. Default is true
. Setting
this property to false
will prevent the window from being fullscreenable on
macOS. On Windows versions older than Windows 11 Build 22000 this property has
no effect, and frameless windows will not have rounded corners.
Optional
screenRepresents the complete screen layout for all available displays. This field is used to determine if the layout was updated since the electron window was last opened, in which case we want to invalidate the stored options and use the default options instead.
Optional
showWhether window should be shown when created. Default is true
.
Optional
simpleUse pre-Lion fullscreen on macOS. Default is false
.
Optional
skipWhether to show the window in taskbar. Default is false
.
Optional
tabbingTab group name, allows opening the window as a native tab. Windows with the same
tabbing identifier will be grouped together. This also adds a native new tab
button to your window's tab bar and allows your app
and window to receive the
new-window-for-tab
event.
Optional
thickUse WS_THICKFRAME
style for frameless windows on Windows, which adds standard
window frame. Setting it to false
will remove window shadow and window
animations. Default is true
.
Optional
titleDefault window title. Default is "Electron"
. If the HTML tag <title>
is
defined in the HTML file loaded by loadURL()
, this property will be ignored.
Optional
titleWhen using a frameless window in conjunction with
win.setWindowButtonVisibility(true)
on macOS or using a titleBarStyle
so
that the standard window controls ("traffic lights" on macOS) are visible, this
property enables the Window Controls Overlay JavaScript APIs and CSS Environment
Variables. Specifying true
will result in an overlay with default system
colors. Default is false
.
Optional
titleThe style of window title bar. Default is default
. Possible values are:
Optional
trafficSet a custom position for the traffic light buttons in frameless windows.
Optional
transparentMakes the window transparent. Default is false
. On Windows, does not work
unless the window is frameless.
Optional
typeThe type of window, default is normal window. See more about this below.
Optional
useThe width
and height
would be used as web page's size, which means the
actual window's size will include window frame's size and be slightly larger.
Default is false
.
Optional
vibrancyAdd a type of vibrancy effect to the window, only on macOS. Can be
appearance-based
, titlebar
, selection
, menu
, popover
, sidebar
,
header
, sheet
, window
, hud
, fullscreen-ui
, tooltip
, content
,
under-window
, or under-page
.
Optional
visualSpecify how the material appearance should reflect window activity state on
macOS. Must be used with the vibrancy
property. Possible values are:
Optional
webSettings of web page's features.
Optional
widthWindow's width in pixels. Default is 800
.
Optional
x(required if y is used) Window's left offset from screen. Default is to center the window.
Optional
y(required if x is used) Window's top offset from screen. Default is to center the window.
Optional
zoomControls the behavior on macOS when option-clicking the green stoplight button
on the toolbar or by clicking the Window > Zoom menu item. If true
, the window
will grow to the preferred width of the web page when zoomed, false
will cause
it to zoom to the width of the screen. This will also affect the behavior when
calling maximize()
directly. Default is false
.
Theia tracks the maximized state of Electron Browser Windows.