Canvas resizes depending on path length.