setRegion method

void setRegion(
  1. int left,
  2. int top,
  3. int width,
  4. int height,
  5. bool v,
)

Implementation

void setRegion(int left, int top, int width, int height, bool v) {
  for (int y = top; y < top + height; y++) {
    for (int x = left; x < left + width; x++) {
      set(x, y, v);
    }
  }
}