protected virtual Bitmap CreateGridTileImage(int cellSize, Color firstColor, Color secondColor) { float scale; // rescale the cell size switch (GridScale) { case ImageBoxGridScale.Medium: scale = 1.5F; break; case ImageBoxGridScale.Large: scale = 2; break; case ImageBoxGridScale.Tiny: scale = 0.5F; break; default: scale = 1; break; } cellSize = (int)(cellSize * scale); return CreateCheckerBoxTile(cellSize, firstColor, secondColor); }