[CSSRegions] Compute region ranges for inline replaced elements
https://bugs.webkit.org/show_bug.cgi?id=128800

Reviewed by Andrei Bucur.

Source/WebCore:

Tests: fast/regions/hover-content-inside-iframe-in-region.html
       fast/regions/select-multiple-in-region.html

When asking for the range of regions for an inline replaced box,
use the region cached on the root inline box for the inline replaced
box as the range of regions is computed only for blocks.
A future patch will extend the computation of region ranges
for inline blocks too.

* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::mapAbsoluteToLocalPoint):
Remove the restriction set during https://bugs.webkit.org/show_bug.cgi?id=113703
and enable the code path for boxes not only for blocks.
Method RenderFlowThread::getRegionRangeForBox returns a null region when it is unable
to get the region range and we already check for null region case.
* rendering/RenderFlowThread.cpp:
(WebCore::RenderFlowThread::getRegionRangeForBox):

LayoutTests:

* fast/regions/hover-content-inside-iframe-in-region-expected.html: Added.
* fast/regions/hover-content-inside-iframe-in-region.html: Added.
* fast/regions/resources/iframe-in-region-source.html: Added.
* fast/regions/select-multiple-in-region-expected.txt: Added.
* fast/regions/select-multiple-in-region.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@164290 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed EFL gardening.

Add test expecations for failing and crashing tests.

* platform/efl-wk2/TestExpectations:
* platform/efl/TestExpectations:
* platform/efl/fast/forms/search/search-size-with-decorations-expected.png: Added after r164145.
* platform/efl/fast/forms/search/search-size-with-decorations-expected.txt: Ditto.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@164291 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Web Inspector: color picker sliders sometime look wrong on Retina display
https://bugs.webkit.org/show_bug.cgi?id=128963

Reviewed by Timothy Hatcher.

Round the values used to position and size popovers in order to ensure that their content don't suffer
from poor pixel alignment on Retina displays.

* UserInterface/Popover.js:
(WebInspector.Popover.prototype.set frame):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@164292 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK] Unreviewed fix. Correct wrong flags, ENABLE(GTK)->PLATFORM(GTK).

* platform/graphics/opengl/Extensions3DOpenGL.cpp:
(WebCore::Extensions3DOpenGL::drawArraysInstanced):
(WebCore::Extensions3DOpenGL::drawElementsInstanced):
(WebCore::Extensions3DOpenGL::vertexAttribDivisor):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@164293 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore: [CSS Blending] Add -webkit-blend-mode support for SVG.

https://bugs.webkit.org/show_bug.cgi?id=110427
Patch by Mihai Tica <mitica@adobe.com> on 2014-02-18
Reviewed by Dirk Schulze.

Add support for blend modes to SVG. This includes adding and validating isolation for blending.
Make masked elements isolate blending by creating a transparency layer.

Tests: css3/compositing/svg-blend-color-burn.html
       css3/compositing/svg-blend-color-dodge.html
       css3/compositing/svg-blend-color.html
       css3/compositing/svg-blend-darken.html
       css3/compositing/svg-blend-difference.html
       css3/compositing/svg-blend-exclusion.html
       css3/compositing/svg-blend-hard-light.html
       css3/compositing/svg-blend-hue.html
       css3/compositing/svg-blend-layer-blend.html
       css3/compositing/svg-blend-layer-clip-path.html
       css3/compositing/svg-blend-layer-filter.html
       css3/compositing/svg-blend-layer-mask.html
       css3/compositing/svg-blend-layer-opacity.html
       css3/compositing/svg-blend-layer-shadow.html
       css3/compositing/svg-blend-lighten.html
       css3/compositing/svg-blend-luminosity.html
       css3/compositing/svg-blend-multiply-alpha.html
       css3/compositing/svg-blend-multiply.html
       css3/compositing/svg-blend-normal.html
       css3/compositing/svg-blend-overlay.html
       css3/compositing/svg-blend-saturation.html
       css3/compositing/svg-blend-screen.html
       css3/compositing/svg-blend-soft-light.html

* rendering/RenderElement.cpp:
(WebCore::RenderElement::styleDidChange): Also pass a pointer to the old style when calling SVGRenderSupport::styleChanged.
* rendering/style/RenderStyle.h:  Add blendMode default getter when CSS_COMPOSITING is disabled.
* rendering/style/SVGRenderStyle.h:
(WebCore::SVGRenderStyle::isolatesBlending): Add method.
* rendering/svg/SVGRenderSupport.cpp:
(WebCore::SVGRenderSupport::styleChanged): Call updateMaskedAncestorShouldIsolateBlending only when a blend mode is set/unset.
(WebCore::SVGRenderSupport::isolatesBlending): Implement method that decides whether an SVGElement isolates or not blending.
(WebCore::SVGRenderSupport::updateMaskedAncestorShouldIsolateBlending): Traverse to the nearest ancestor having a mask.
- Set a flag causing the creation of a transparency layer when rendering the masked element.
* rendering/svg/SVGRenderSupport.h:
* rendering/svg/SVGRenderingContext.cpp:
(WebCore::SVGRenderingContext::prepareToRenderSVGContent): Call GraphicsContext::setCompositeOperation.
- Isolate blending by creating a transparency layer.
- Isolate group when rendering a masked element having a blended child node.
* svg/SVGGraphicsElement.cpp:
(WebCore::SVGGraphicsElement::SVGGraphicsElement): Set default m_shouldIsolateBlending to false.
* svg/SVGGraphicsElement.h: Add m_shouldIsolateBlending member, getter and setter.
(WebCore::SVGGraphicsElement::shouldIsolateBlending):
(WebCore::SVGGraphicsElement::setShouldIsolateBlending):

LayoutTests: [CSS Blending] Add -webkit-blend-mode support for SVG.
https://bugs.webkit.org/show_bug.cgi?id=110427

Patch by Mihai Tica <mitica@adobe.com> on 2014-02-18
Reviewed by Dirk Schulze.

Test -webkit-blend-mode implementation for simple SVGs. This includes:
- Test each blend operator.
- Test that ensures blending is isolated by other properties: blending, filters, masks, shadow and opacity.

* css3/compositing/svg-blend-color-burn.html: Test blend mode color-burn.
* css3/compositing/svg-blend-color-dodge.html: Test blend mode color-dodge.
* css3/compositing/svg-blend-color.html: Test blend mode color.
* css3/compositing/svg-blend-darken.html: Test blend mode darken.
* css3/compositing/svg-blend-difference.html: Test blend mode difference.
* css3/compositing/svg-blend-exclusion.html: Test blend mode exclusion.
* css3/compositing/svg-blend-hard-light.html: Test blend mode hard-light.
* css3/compositing/svg-blend-hue.html: Test blend mode hue.
* css3/compositing/svg-blend-layer-blend.html: mix-blend-mode should isolate for blending.
* css3/compositing/svg-blend-layer-clip-path.html: clip-path should not isolate for blending.
* css3/compositing/svg-blend-layer-filter.html: filters should isolate for blending.
* css3/compositing/svg-blend-layer-mask.html: masks should isolate for blending.
* css3/compositing/svg-blend-layer-opacity.html: opacity should isolate for blending.
* css3/compositing/svg-blend-layer-shadow.html: -webkit-shadow should isolate for blending.
* css3/compositing/svg-blend-lighten.html: Test blend mode lighten.
* css3/compositing/svg-blend-luminosity.html: Test blend mode luminosity.
* css3/compositing/svg-blend-multiply-alpha.html: Test blend mode multiply while also having alpha set.
* css3/compositing/svg-blend-multiply.html: Test blend mode multiply.
* css3/compositing/svg-blend-normal.html: Test blend mode normal. Note this blend mode has no effect.
* css3/compositing/svg-blend-overlay.html: Test blend mode overlay.
* css3/compositing/svg-blend-saturation.html: Test blend mode saturation.
* css3/compositing/svg-blend-screen.html: Test blend mode screen.
* css3/compositing/svg-blend-soft-light.html: Test blend mode soft-light.
* platform/mac/css3/compositing/svg-blend-color-burn-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-color-burn-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-color-dodge-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-color-dodge-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-color-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-color-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-darken-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-darken-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-difference-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-difference-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-exclusion-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-exclusion-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-hard-light-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-hard-light-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-hue-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-hue-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-layer-blend-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-layer-blend-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-layer-clip-path-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-layer-clip-path-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-layer-filter-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-layer-filter-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-layer-mask-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-layer-mask-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-layer-opacity-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-layer-opacity-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-layer-shadow-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-layer-shadow-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-lighten-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-lighten-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-luminosity-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-luminosity-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-multiply-alpha-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-multiply-alpha-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-multiply-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-multiply-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-normal-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-normal-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-overlay-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-overlay-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-saturation-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-saturation-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-screen-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-screen-expected.txt: Added.
* platform/mac/css3/compositing/svg-blend-soft-light-expected.png: Added.
* platform/mac/css3/compositing/svg-blend-soft-light-expected.txt: Added.

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