Skip to content

Conversation

@maharshi-gor
Copy link
Contributor

  • Fixed the calculate screen size to respect bbs.
  • Added resize_callback for downstream.
  • callback will be executed first and then regular resize functionality.

@maharshi-gor maharshi-gor requested a review from skoudoro January 8, 2026 21:32
@maharshi-gor maharshi-gor self-assigned this Jan 8, 2026
@maharshi-gor maharshi-gor added type:Bug Fix Something isn't working v2 labels Jan 8, 2026
@maharshi-gor maharshi-gor force-pushed the screen-config-fix branch 2 times, most recently from daf8955 to 919e6bf Compare January 8, 2026 21:52
fury/window.py Outdated
if screens is None or not screens:
return [(0, 0, *size)]

if isinstance(screens[0], (tuple, list)):
Copy link
Contributor

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

Copy link
Contributor Author

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.

if screens is None or not screens:
return [(0, 0, *size)]

if all(isinstance(screen, (tuple, list)) for screen in screens):
Copy link
Contributor

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
Copy link
Contributor

@skoudoro skoudoro left a 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

@skoudoro skoudoro merged commit 6c2cdf0 into fury-gl:v2 Jan 9, 2026
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type:Bug Fix Something isn't working v2

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants