Added canvas size restrictions