Clamp contents visual overflow for LayoutSVGRoot

If the contents overflow rect for the SVG root is too large, it could
end up shifting the overflow rect such that it is culled and thus never
painted.

To avoid this, clip the content overflow rect with
LayoutRect::InfiniteIntRect(). This gives reasonable enough leeway, and
also matches the rect that is commonly used to represent infinity for
culling and clipping etc.

Bug: 911186
Change-Id: I22d505ac0582f4d1fe6ac3ead9041c4a87176994
Reviewed-on: https://chromium-review.googlesource.com/c/1361225
Reviewed-by: Stephen Chenney <schenney@chromium.org>
Commit-Queue: Fredrik Söderquist <fs@opera.com>
Cr-Commit-Position: refs/heads/master@{#613692}
4 files changed