tauri_sys

Module window

source
Expand description

Provides APIs to create windows, communicate with other windows and manipulate the current window.

The APIs must be added to tauri.allowlist.window in tauri.conf.json:

{
    "tauri": {
        "allowlist": {
            "window": {
                "all": true, // enable all window APIs
                "create": true, // enable window creation
                "center": true,
                "requestUserAttention": true,
                "setResizable": true,
                "setTitle": true,
                "maximize": true,
                "unmaximize": true,
                "minimize": true,
                "unminimize": true,
                "show": true,
                "hide": true,
                "close": true,
                "setDecorations": true,
                "setAlwaysOnTop": true,
                "setSize": true,
                "setMinSize": true,
                "setMaxSize": true,
                "setPosition": true,
                "setFullscreen": true,
                "setFocus": true,
                "setIcon": true,
                "setSkipTaskbar": true,
                "setCursorGrab": true,
                "setCursorVisible": true,
                "setCursorIcon": true,
                "setCursorPosition": true,
                "setIgnoreCursorEvents": true,
                "startDragging": true,
                "print": true
            }
        }
    }
}

It is recommended to allowlist only the APIs you use for optimal bundle size and security.

Structs§

Enums§

Functions§