Optimize _initDimensions to not create off-screen canvas every time. Closes #564
Build distribution