Skip to content

Conversation

@bensgilbert
Copy link
Contributor

Resolves #7133

Changes:
Adds a function called upon p5 initialisation which fixes a bug where windowWidth and windowHeight would represent the correct values when the window was resized and no p5 sketch was active

Video of the before:
https://github.com/user-attachments/assets/82ebad21-5d55-4203-870b-184f9b8775e8

PR Checklist

bensgilbert and others added 2 commits July 17, 2024 22:27
This fixes a bug where `windowWidth` and `windowHeight` would represent the correct values when the window was resized and no p5 sketch was active
@welcome
Copy link

welcome bot commented Jul 17, 2024

🎉 Thanks for opening this pull request! Please check out our contributing guidelines if you haven't already. And be sure to add yourself to the list of contributors on the readme page!

Copy link
Contributor

@davepagurek davepagurek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for helping narrow down the cause of this bug!

@bensgilbert
Copy link
Contributor Author

I've just updated where the function is called to run before the init handlers as you suggested

@bensgilbert bensgilbert requested a review from davepagurek July 19, 2024 02:25
Copy link
Contributor

@davepagurek davepagurek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for making those changes, looks great!

@davepagurek davepagurek merged commit e992412 into processing:main Jul 19, 2024
@davepagurek
Copy link
Contributor

@all-contributors please add @Evorage0 for bug, code

@allcontributors
Copy link
Contributor

@davepagurek

I've put up a pull request to add @Evorage0! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Inconsistent instance mode canvas sizing

2 participants