SVG Generator: Output path closing command for closed subpaths
QPainterPath does not provide any explicit flag for closed
subpaths. By convention, all subpaths that start and end in the same
point are regarded as closed.
The SVG <path> command, on the other hand, requires an explicit Z
command for a subpath to be closed (i.e. to join the start and end
points). This commit adds functionality to output those commands as
needed.
Pick-to: 6.11
Task-number: QTBUG-143451
Change-Id: I626c550dbdfb30c4265781324e8d00e470d9f849
Reviewed-by: Hatem ElKharashy <hatem.elkharashy@qt.io>