p5.js
p5.js copied to clipboard
Slight mistake in description of scale() effect in reference
Increasing access
This issue pertains to the reference for one of the functions. A clearer reference helps with accessibility for everyone.
Most appropriate sub-area of p5.js?
- [ ] Accessibility
- [ ] Color
- [X] Core/Environment/Rendering
- [ ] Data
- [ ] DOM
- [ ] Events
- [ ] Image
- [ ] IO
- [ ] Math
- [ ] Typography
- [ ] Utilities
- [ ] WebGL
- [ ] Build process
- [ ] Unit testing
- [ ] Internationalization
- [ ] Friendly errors
- [ ] Other (specify if possible)
Feature enhancement details
The reference page for the scale() function contains the following:
By default, transformations accumulate. For example, calling
scale(1)twice has the same effect as callingscale(2)once. The push() and pop() functions can be used to isolate transformations within distinct drawing groups.
This is incorrect, as calling scale(1) twice does nothing, since a coefficient of 1 does not change the scale. To provide a correct and clear example, the following can be written instead:
[...] For example, calling
scale(2)twice has the same effect as callingscale(4)once.
Welcome! 👋 Thanks for opening your first issue here! And to ensure the community is able to respond to your issue, please make sure to fill out the inputs in the issue forms. Thank you!
Thanks @Nuclear-Crow! Tagging @nickmcintyre to take a look
Good catch @Nuclear-Crow!