Screen Col

screenCol() #

Returns the quadrille col to which the screen space pixelX coordinate belong.

Observations

  1. screenCol() returns a value not constrain to lie in [0..width].
  2. If the quadrille is currently being drawn use the mouseCol property instead.

Syntax #

screenCol(pixelX)

screenCol(pixelX, x, cellLength)

Parameters #

parameterdescription
pixelXNumber: screen space x-coord
xNumber: quadrille upper left corner x-coord. If not provided it’s value is inferred from drawQuadrille
cellLengthNumber: cell length. If not provided it’s value is inferred from drawQuadrille