tauri-apps / tauri-apps/plugins-workspace

`window-state`: window shrinks by the height of the menu on every reopen

Open
#2,733 1 comment 0 reactions 0 assignees View on GitHub
plugin: window-state status: upstream type: bug
Dominant language
Rust
Stars
1.8k
Forks
602
Avg merge
4d 14h
Merged PRs (30d)
9

Description

I believe there is a discrepancy between `set_size()` and `inner_size()`.

https://github.com/tauri-apps/plugins-workspace/blob/d40190721ccf36a00d666a03800e972514fc379c/plugins/window-state/src/lib.rs#L210-L215

https://github.com/tauri-apps/plugins-workspace/blob/d40190721ccf36a00d666a03800e972514fc379c/plugins/window-state/src/lib.rs#L304-L309

At least on Windows, `inner_size()` seems to not account for the height of the menu. So every time the window is reopened, it gets a little shorter. In fact, exactly as shorter as the height of the menu.

![Image](https://github.com/user-attachments/assets/d1818a79-dcb0-4984-bde8-528a567f3049)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.