[CSS Exclusions] Refactor the ExclusionPolygon class to enable storing multiple boundaries
https://bugs.webkit.org/show_bug.cgi?id=111766

Reviewed by Dirk Schulze.

Refactored the ExclusionPolygon class to enable adding support for shape-margin and shape-padding.
Extracted a new FloatPolygon class which is now used by ExclusionPolygon to represent the shape's
boundary. It will be used to add m_paddedPolygon and m_marginPolygon members to ExclusionPolygon
in a subsequent patch.

No new tests. This is strictly a refactoring of the existing code.

* CMakeLists.txt:
* GNUmakefile.list.am:
* WebCore.gypi:
* WebCore.vcproj/WebCore.vcproj:
* WebCore.xcodeproj/project.pbxproj:
* platform/graphics/FloatPolygon.cpp: Factored out of Source/WebCore/rendering/ExclusionPolygon.cpp.
(WebCore::determinant):
(WebCore::areCollinearPoints):
(WebCore::areCoincidentPoints):
(WebCore::isPointOnLineSegment):
(WebCore::nextVertexIndex):
(WebCore::FloatPolygon::FloatPolygon):
(WebCore::FloatPolygon::findNextEdgeVertexIndex):
(WebCore::FloatPolygon::overlappingEdges):
(WebCore::leftSide):
(WebCore::FloatPolygon::contains):
(WebCore::VertexPair::overlapsRect):
(WebCore::VertexPair::intersection):
* platform/graphics/FloatPolygon.h: Factored out of Source/WebCore/rendering/ExclusionPolygon.h.
(FloatPolygon):
(WebCore::FloatPolygon::vertexAt):
(WebCore::FloatPolygon::numberOfVertices):
(WebCore::FloatPolygon::fillRule):
(WebCore::FloatPolygon::edgeAt):
(WebCore::FloatPolygon::numberOfEdges):
(WebCore::FloatPolygon::boundingBox):
(WebCore::FloatPolygon::isEmpty):
(VertexPair):
(WebCore::VertexPair::~VertexPair):
(WebCore::VertexPair::minX):
(WebCore::VertexPair::minY):
(WebCore::VertexPair::maxX):
(WebCore::VertexPair::maxY):
(FloatPolygonEdge):
(WebCore::FloatPolygonEdge::previousEdge):
(WebCore::FloatPolygonEdge::nextEdge):
(WebCore::FloatPolygonEdge::polygon):
(WebCore::FloatPolygonEdge::vertexIndex1):
(WebCore::FloatPolygonEdge::vertexIndex2):
(WebCore::FloatPolygonEdge::edgeIndex):
* rendering/ExclusionPolygon.cpp: Now depends on FloatPolygon.
(EdgeIntersection):
(WebCore::leftSide):
(WebCore::computeXIntersection):
(WebCore::getVertexIntersectionVertices):
(WebCore::computeXIntersections):
(WebCore::computeOverlappingEdgeXProjections):
(WebCore::ExclusionPolygon::getExcludedIntervals):
(WebCore::ExclusionPolygon::getIncludedIntervals):
(WebCore::firstFitRectInPolygon):
(WebCore::ExclusionPolygon::firstIncludedIntervalLogicalTop):
* rendering/ExclusionPolygon.h: Now depends on FloatPolygon.
(WebCore::OffsetPolygonEdge::OffsetPolygonEdge):
(ExclusionPolygon):
(WebCore::ExclusionPolygon::ExclusionPolygon):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@145411 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Some StringHasher tests are broken because of missing null termination
https://bugs.webkit.org/show_bug.cgi?id=111284

Reviewed by Darin Adler.

* TestWebKitAPI/Tests/WTF/StringHasher.cpp:
(TestWebKitAPI): Added null termination since C strings are null-terminated.
(TestWebKitAPI::TEST): Removed #ifdef's that disabled this testing since
the bug caught by it is now fixed.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@145412 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Fix typo from r145399. Rubber stamped by Abhishek Arya.

* rendering/svg/RenderSVGViewportContainer.h:
(WebCore::toRenderSVGViewportContainer):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@145413 268f45cc-cd09-0410-ab3c-d52691b4dbfc