Zooming an SVG in compare mode allowed the SVG to be painted outside its
parent widget SvgImageView, effectively overlapping the selection rect
which is drawn in DocumentView::paint. This patch clips all painting
done by children of AbstractImageView to its own shape, therefore
fixing the issue.
Before:
After: