A window with decorations can't be transparent initially until resized
Describe the bug A clear and concise description of what the bug is. Create transparent window in win10,start app background still white, But maximize the window extra part can transparent . When resize cover the white space,Area becomes transparent.
To Reproduce Steps to reproduce the behavior:
- Go to '...'
- Click on '....'
- Scroll down to '....'
- See error
Expected behavior A clear and concise description of what you expected to happen.
Screenshots If applicable, add screenshots to help explain your problem.

Platform and Versions (please complete the following information):
Operating System - Windows, version 10.0.19042 X64 Webview2 - 90.0.818.62
Node.js environment Node.js - 14.17.0 @tauri-apps/cli - 1.0.0-beta.1 @tauri-apps/api - 1.0.0-beta.1
Global packages npm - 6.14.13 yarn - 1.22.10
Rust environment rustc - 1.52.1 cargo - 1.52.0
App directory structure /.git /node_modules /public /src /src-tauri
App tauri.rs - 1.0.0-beta.1 build-type - bundle CSP - default-src blob: data: filesystem: ws: http: https: 'unsafe-eval' 'unsafe-inline' img-src: 'self' distDir - Set automatically by Vue CLI plugin devPath - Set automatically by Vue CLI plugin framework - Vue.js (Vue CLI) bundler - Webpack
Additional context Add any other context about the problem here.
Stack Trace
I poked around and found out:
- Transparent on electron only works when used in a frameless window, Regular windows cannot be transparent, probably they are using the same api as us.
- We could draw to the window like glutin transparent example but with decorations on.
TBH, I am tempted to close this issue and recommend to always use transparent with decorations off but I will keep this open for now.
Just found a workaround, set your decorations to false in tauri.conf, then when your app is loaded use the Javascript API to reset it to true. Worked for me