Fix off-by-one bug in canvas width