-
Notifications
You must be signed in to change notification settings - Fork 192
BF: Screen Config can be bounding box. #1069
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
Conversation
maharshi-gor
commented
Jan 8, 2026
- Fixed the calculate screen size to respect bbs.
- Added resize_callback for downstream.
- callback will be executed first and then regular resize functionality.
daf8955 to
919e6bf
Compare
fury/window.py
Outdated
| if screens is None or not screens: | ||
| return [(0, 0, *size)] | ||
|
|
||
| if isinstance(screens[0], (tuple, list)): |
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.
I did not look at the rest of the codebase, I need to check
but why screens[0] and not screens[1]. I am sure there is a logic but I need to go deeper
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.
The screens[0] can be int in the case of basic configuration like
screens = [1, 2, 4]
Here each element means how many sections along the width and the number itself means how many sub-sections along the height in that particular section.
The more not used way is to provide the bounding boxes in which
screen = [(x0, y0 w0, h0), (x1, y1, w1, h1)]
Given that we can check all of the screen configuration. That will be bulletproof.
919e6bf to
9fb9eca
Compare
| if screens is None or not screens: | ||
| return [(0, 0, *size)] | ||
|
|
||
| if all(isinstance(screen, (tuple, list)) for screen in screens): |
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.
ok, great!
I think it is ready to go but one last comment:
can you update the docstring of screens. It will help to understand. Thank you
- Fixed the calculate screen size to respect bbs. - Added resize_callback for downstream. - callback will be executed first and then regular resize functionality. - Test cases for valid bounding box
9fb9eca to
1162c7e
Compare
skoudoro
left a comment
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.
All good, Thanks @maharshi-gor, merging