-
-
Notifications
You must be signed in to change notification settings - Fork 201
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Setting initial window size on GTK sets the wrong size #929
Comments
I can reproduce the problem on Gnome Wayland on Fedora I think. I think the problem is that hiding decorations after setting the internal_size doesn't change the size which was allocated for the titlebar. When setting up stuff from the window builder it works in that order, size then decorations. |
I encountered this problem with Gnome Wayland on Ubuntu 24.04. Use the example in the
My test indicates that it breaks since tao 0.30.3. I added logs around the following code and found that the size differs after the tao/src/platform_impl/linux/window.rs Lines 227 to 231 in d0e46ad
Bellow is the test result with tao 0.30.3 I tested the code changes in #984 and found that it fixed this problem visually (I mean, while the webview size is correct, the logged size is incorrect for both width and height). Rolling back to 0.30.2 can get the correct size for both the visual and logged sizes. However, the window cannot move (this could be the problem tauri-apps/tauri#10686). |
Describe the bug
I am using tao on weston with CentOS 9. Using the WindowBuilder
with_inner_size
doesn't seem to give the same inner_size.Steps To Reproduce
I have attached an adjusted example from here to show this, just start it and press spacebar a few times.
Firstly it seems like inner_size and outer_size are always equal on Linux?
Expected behavior
with_inner_size(PhysicalSize::new(240, 240))
should make a window with a content area of 240x240. At the moment I get 240x277Platform and Versions (please complete the following information):
OS: CentOS Stream 9, weston 8
Rustc: rustc 1.77.2
Additional context
It seems like I can work around this by setting the inner_size again after window decorations have been disabled.
The text was updated successfully, but these errors were encountered: