span
Gets the smallest axis-aligned rectangle that contains all filled cells. Returns an object of the form { row, col, width, height }, or undefined if the quadrille is entirely empty.
Example
(mouse click to toggle emojis; press any key to randomize the quadrille)
Syntax
{ row, col, width, height } | undefined= quadrille.span
What this page's examples use
- p5.quadrille
drawQuadrillecreateQuadrillecellLengthmouseRowmouseColfillclearrandomizeisValidisFilledspan- p5.js
createCanvasbackground
Names the analysis can prove are called, and the line each one is documented on. Local variables and members of an unknown receiver are left out.