-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Resizing a window allows it to be dragged outside of the screen. #202
Comments
I wanted to fix this, but I think this is by design. Looking at the following snippet: Lines 487 to 516 in f5c3729
Now the discussion is, should we limit it to the screen size or should we keep as designed? One idea I have is to make it configurable. If a I thought this a good |
I had actually tried playing around with this method as to simply constrain the Before adding anything like this though, its probably better getting @emilk 's input on the matter. |
👋 To understand the motivation of the current behavior: resize the egui frame window to the size of a phone screen (or open the web demo on a mobile phone). Some windows are too wide to fit the screen, and all need to be able to cover the side bar to fit. When the screen is wide enough, however, I think it makes sense to only allow the windows on the central panel area. I agree this is a bit confusing. An option to toggle the behavior would not solve the core problem. I think the best solution (from a UI perspective) is to have a collapsible side bar so that for phone screens the side bar becomes a hamburger-menu or similar. That way the "allow windows to overlap sidebar" feature wouldn't be needed. Some of the other confusing behavior in the gif comes from making the widget windows very large. In many cases it may make sense to have a maximum width, or restricting the resizing mouse cursor to the inside of the screen. There is also the separate issue of moving a window by dragging the top edge of it: this is more of a bug, or an artifact of how resizing is done. It is a bit hard to handle it well in immediate mode without frame delay. |
Hello,
Resizing a
Window
can cause the window to go outside of the boundaries of the screen and allows the window to be extended over the side or top panels, where it normally cannot be dragged. This can be reproduced more easily on a smaller screen space on desktop.The text was updated successfully, but these errors were encountered: