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
Fix: egui::Window size recognition issue #4388
base: master
Are you sure you want to change the base?
Conversation
crates/egui/src/containers/window.rs
Outdated
if let Some(mut state) = resize::State::load(ctx, resize_id) { | ||
state.desired_size = last_frame_outer_rect.size() - margins; | ||
state.store(ctx, resize_id); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix 1: egui::Window size recognition issue
The biggest problem (bug) solution is saving state
.
Thanks for taking a shot at this. I tried it and it does fix the issue. However, the fix seems to have had some unintended side effects. For example, when increasing the size of a window, its contents will always be scaled to the maximum size that the window had at any point. On the master branch, they would take up less space again as the window is made smaller. |
This is completed. Removed another commit. |
Fix : egui::Window size recognition issue
This is completed. Removed another commit.
It will be easier to check the problem using the example below.