[CSS Regions] Fix painting when the composited region has overflow:hidden
https://bugs.webkit.org/show_bug.cgi?id=124887

Patch by Mihai Maerean <mmaerean@adobe.com> on 2014-01-15
Reviewed by Alexandru Chiculita.

Source/WebCore:

When the layer of the region is composited, the region receives a GraphicsLayer of its own
so the clipping coordinates (caused by overflow:hidden) must be relative to the
GraphicsLayer coordinates in which the region gets painted.

Also, while the painting is done relative to the location of the region's content box, the
clipping is bound to the padding box of the region.

Tests: compositing/regions/paint-inside-composited-region-overflow-hidden-versus-div.html
       compositing/regions/paint-inside-composited-region-overflow-hidden-versus-region.html

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::paintFlowThreadIfRegion):

LayoutTests:

* compositing/regions/paint-inside-composited-region-overflow-hidden-versus-div.html: Added.
* compositing/regions/paint-inside-composited-region-overflow-hidden-versus-div-expected.html: Added.
* compositing/regions/paint-inside-composited-region-overflow-hidden-versus-region.html: Added.
* compositing/regions/paint-inside-composited-region-overflow-hidden-versus-region-expected.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@162115 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Fix the iOS build after r162114

Unreviewed.

Patch by Benjamin Poulain <bpoulain@apple.com> on 2014-01-15

Source/WebCore: 

* WebCore.exp.in: Move the symbol to the right section and add the missing symbols for iOS.

Source/WebKit/mac: 

* WebView/WebViewPrivate.h: I forgot to remove the declaration, fix that.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@162116 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[CSS Regions] Enable accelerated compositing for fixed elements in named flows
https://bugs.webkit.org/show_bug.cgi?id=125144

Reviewed by David Hyatt.

Source/WebCore:

Add support for compositing for fixed positioned element that are collected
inside a named flow. Prior to this patch, the fixed positioned elements were
positioned and sized properly but only in the non-compositing scenario.

Tests: compositing/regions/abs-in-named-flow-from-fixed-in-named-flow.html
       compositing/regions/fixed-in-diff-named-flows-zIndex.html
       compositing/regions/fixed-in-named-flow-clip-descendant.html
       compositing/regions/fixed-in-named-flow-from-abs-in-named-flow.html
       compositing/regions/fixed-in-named-flow-from-outflow.html
       compositing/regions/fixed-in-named-flow-got-transformed-parent.html
       compositing/regions/fixed-in-named-flow-lost-transformed-parent.html
       compositing/regions/fixed-in-named-flow-overlap-composited.html
       compositing/regions/fixed-in-named-flow-position-changed.html
       compositing/regions/fixed-in-named-flow-transformed-parent.html
       compositing/regions/fixed-in-named-flow-zIndex.html
       compositing/regions/fixed-in-named-flow.html
       compositing/regions/fixed-transformed-in-named-flow.html

* rendering/RenderFlowThread.cpp:
(WebCore::RenderFlowThread::regionForCompositedLayer):
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::computeCompositingRequirementsForNamedFlowFixed):
(WebCore::RenderLayerCompositor::computeCompositingRequirements):
(WebCore::RenderLayerCompositor::rebuildCompositingLayerTreeForNamedFlowFixed):
(WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
(WebCore::RenderLayerCompositor::updateLayerTreeGeometry):
(WebCore::RenderLayerCompositor::requiresCompositingForPosition):
* rendering/RenderLayerCompositor.h:
* rendering/RenderNamedFlowFragment.h:
* rendering/RenderNamedFlowThread.h:

LayoutTests:

Added new tests and made the existing tests for fixed positioned elements use the
non-compositing mode.

* compositing/regions/abs-in-named-flow-from-fixed-in-named-flow-expected.txt: Added.
* compositing/regions/abs-in-named-flow-from-fixed-in-named-flow.html: Added.
* compositing/regions/fixed-in-diff-named-flows-zIndex-expected.html: Added.
* compositing/regions/fixed-in-diff-named-flows-zIndex.html: Added.
* compositing/regions/fixed-in-named-flow-clip-descendant-expected.txt: Added.
* compositing/regions/fixed-in-named-flow-clip-descendant.html: Added.
* compositing/regions/fixed-in-named-flow-expected.txt: Added.
* compositing/regions/fixed-in-named-flow-from-abs-in-named-flow-expected.txt: Added.
* compositing/regions/fixed-in-named-flow-from-abs-in-named-flow.html: Added.
* compositing/regions/fixed-in-named-flow-from-outflow-expected.txt: Added.
* compositing/regions/fixed-in-named-flow-from-outflow.html: Added.
* compositing/regions/fixed-in-named-flow-got-transformed-parent-expected.txt: Added.
* compositing/regions/fixed-in-named-flow-got-transformed-parent.html: Added.
* compositing/regions/fixed-in-named-flow-lost-transformed-parent-expected.txt: Added.
* compositing/regions/fixed-in-named-flow-lost-transformed-parent.html: Added.
* compositing/regions/fixed-in-named-flow-overlap-composited-expected.txt: Added.
* compositing/regions/fixed-in-named-flow-overlap-composited.html: Added.
* compositing/regions/fixed-in-named-flow-position-changed-expected.html: Added.
* compositing/regions/fixed-in-named-flow-position-changed.html: Added.
* compositing/regions/fixed-in-named-flow-transformed-parent-expected.txt: Added.
* compositing/regions/fixed-in-named-flow-transformed-parent.html: Added.
* compositing/regions/fixed-in-named-flow-zIndex-expected.html: Added.
* compositing/regions/fixed-in-named-flow-zIndex.html: Added.
* compositing/regions/fixed-in-named-flow.html: Added.
* compositing/regions/fixed-transformed-in-named-flow-expected.txt: Added.
* compositing/regions/fixed-transformed-in-named-flow.html: Added.
* fast/regions/repaint/element-in-named-flow-absolute-from-fixed.html:
* fast/regions/repaint/element-in-named-flow-fixed-from-absolute.html:
* fast/regions/repaint/element-inflow-fixed-from-outflow-static.html:
* fast/regions/repaint/element-outflow-static-from-inflow-fixed.html:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@162117 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK][EFL][NIX] Do not use PrintContext, Frame and DocumentLoader in Errors
https://bugs.webkit.org/show_bug.cgi?id=127047

Reviewed by Martin Robinson.

Source/WebCore:

Using PrintContext, Frame and DocumentLoader in platform is a
layering violation.
Change printing error methods to receive a failing URL instead of
receiving a PrintContext that was used only to get the failing
URL.

* platform/efl/ErrorsEfl.cpp:
(WebCore::printError):
(WebCore::printerNotFoundError):
(WebCore::invalidPageRangeToPrint):
* platform/efl/ErrorsEfl.h:
* platform/gtk/ErrorsGtk.cpp:
(WebCore::printError):
(WebCore::printerNotFoundError):
(WebCore::invalidPageRangeToPrint):
* platform/gtk/ErrorsGtk.h:
* platform/nix/ErrorsNix.cpp:
(WebCore::printError):
(WebCore::printerNotFoundError):
(WebCore::invalidPageRangeToPrint):
* platform/nix/ErrorsNix.h:

Source/WebKit2:

* WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp:
(WebKit::WebPrintOperationGtk::frameURL): Helper function to get
the URL of the frame being printed.
(WebKit::WebPrintOperationGtk::print): Use frameURL() as failing
URL for printing errors.
* WebProcess/WebPage/gtk/WebPrintOperationGtk.h:

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