Move zero-length-subpaths from RenderSVGShape to RenderSVGPath
https://bugs.webkit.org/show_bug.cgi?id=90716

Reviewed by Nikolas Zimmermann.

Previously zero-length-subpath code was present in RenderSVGShape but it is
only needed in RenderSVGPath. This patch moves the zero-length-subpath code
to RenderSVGPath.

In this change, we gain:
1) Ellipses, Circles, and Rects will no longer carry an empty Vector nor
   checks for zero-length subpaths which (per the spec) they cannot have.
2) RenderSVGShape, the superclass of all shape rendering, has been
   drastically simplified by removing 70 lines of code that only applies
   to Path rendering. This generally aids in code understandability.

The patch is primarily a straightforward code move but useStrokeStyleToFill
needs further explanation:
Zero-length-subpaths are drawn using rectangular and circular paths which
are filled.
Previously in RenderSVGShape::fillAndStrokePath, strokePath was called for
the main path with ApplyToStrokeMode and then strokePath was called for
each zero-length-subpath with ApplyToFillMode.
ApplyToFillMode had the effect of setting the context's stroke style to
the fill style so zero-length-subpaths were "filled" with the stroke style.
After this patch, the context is only setup once (which is faster!) using
ApplyToStrokeMode so we manually set the stroke style to the fill style
using useStrokeStyleToFill.

No new tests, just a refactoring.

* rendering/svg/RenderSVGPath.cpp:
(WebCore::RenderSVGPath::updateShapeFromElement):
(WebCore):
(WebCore::RenderSVGPath::calculateUpdatedStrokeBoundingBox):
(WebCore::useStrokeStyleToFill):
(WebCore::RenderSVGPath::strokeShape):
(WebCore::RenderSVGPath::shapeDependentStrokeContains):
(WebCore::RenderSVGPath::shouldStrokeZeroLengthSubpath):
(WebCore::RenderSVGPath::zeroLengthLinecapPath):
(WebCore::RenderSVGPath::zeroLengthSubpathRect):
(WebCore::RenderSVGPath::updateZeroLengthSubpaths):
* rendering/svg/RenderSVGPath.h:
(RenderSVGPath):
* rendering/svg/RenderSVGShape.cpp:
(WebCore::RenderSVGShape::updateShapeFromElement):
(WebCore::RenderSVGShape::strokeShape):
(WebCore::RenderSVGShape::strokeContains):
(WebCore):
(WebCore::RenderSVGShape::fillShape):
(WebCore::RenderSVGShape::fillAndStrokeShape):
(WebCore::RenderSVGShape::paint):
(WebCore::RenderSVGShape::calculateStrokeBoundingBox):
* rendering/svg/RenderSVGShape.h:
(WebCore::RenderSVGShape::hasPath):
(WebCore::RenderSVGShape::hasNonScalingStroke):
(RenderSVGShape):
(WebCore::RenderSVGShape::strokeBoundingBox):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122875 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Remove unnecessary clearWindow() calls and the method itself
https://bugs.webkit.org/show_bug.cgi?id=91540
RIM PR 174365

Reviewed by Adam Treat.

If we resume the backingstore right afterwards with
RenderAndBlit then that'll fill the whole visible area
with content, making a clearWindow() call unnecessary.
This call is a remnant from ages ago, and is well suited
to disappear into nothingness.

(There is still a clearWindow() call, with rect argument,
which we continue using. This commit only removes the
rect-less version.)

* Api/BackingStore.cpp:
* Api/BackingStore_p.h:
(BackingStorePrivate):
* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::zoomAboutPoint):
(BlackBerry::WebKit::WebPagePrivate::zoomBlock):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122876 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Qt] svg/transforms tests needs update after rebaseline and new testfonts
https://bugs.webkit.org/show_bug.cgi?id=91501

Patch by Bruno de Oliveira Abinader <bruno.abinader@basyskom.com> on 2012-07-17
Reviewed by Alexis Menard.

Updated expected Qt results for most svg/transforms layout tests, after testfonts changes made by bug 85203.

* platform/qt-5.0/Skipped:
* platform/qt-5.0/svg/transforms/text-with-mask-with-svg-transform-expected.png:
* platform/qt-5.0/svg/transforms/text-with-mask-with-svg-transform-expected.txt:
* platform/qt-5.0/svg/transforms/text-with-pattern-inside-transformed-html-expected.png:
* platform/qt-5.0/svg/transforms/text-with-pattern-inside-transformed-html-expected.txt:
* platform/qt-5.0/svg/transforms/text-with-pattern-with-svg-transform-expected.png:
* platform/qt-5.0/svg/transforms/text-with-pattern-with-svg-transform-expected.txt:
* platform/qt/svg/transforms/animated-path-inside-transformed-html-expected.png:
* platform/qt/svg/transforms/animated-path-inside-transformed-html-expected.txt:
* platform/qt/svg/transforms/svg-css-transforms-clip-path-expected.png:
* platform/qt/svg/transforms/svg-css-transforms-clip-path-expected.txt:
* platform/qt/svg/transforms/svg-css-transforms-expected.png:
* platform/qt/svg/transforms/svg-css-transforms-expected.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122878 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Qt] fast/forms tests needs update after rebaseline and new testfonts
https://bugs.webkit.org/show_bug.cgi?id=91504

Patch by Bruno de Oliveira Abinader <bruno.abinader@basyskom.com> on 2012-07-17
Reviewed by Alexis Menard.

Updated expected Qt results for most fast/forms layout tests, after testfonts changes made by bug 85203.

* platform/qt-5.0-wk1/Skipped:
* platform/qt-5.0-wk2/Skipped:
* platform/qt-5.0/Skipped:
* platform/qt-5.0/fast/forms/HTMLOptionElement_label06-expected.png:
* platform/qt-5.0/fast/forms/HTMLOptionElement_label06-expected.txt:
* platform/qt-5.0/fast/forms/HTMLOptionElement_label07-expected.png:
* platform/qt-5.0/fast/forms/HTMLOptionElement_label07-expected.txt:
* platform/qt-5.0/fast/forms/box-shadow-override-expected.png:
* platform/qt-5.0/fast/forms/box-shadow-override-expected.txt:
* platform/qt-5.0/fast/forms/form-element-geometry-expected.png:
* platform/qt-5.0/fast/forms/form-element-geometry-expected.txt:
* platform/qt-5.0/fast/forms/input-disabled-color-expected.png:
* platform/qt-5.0/fast/forms/input-disabled-color-expected.txt:
* platform/qt-5.0/fast/forms/listbox-bidi-align-expected.txt:
* platform/qt-5.0/fast/forms/menulist-separator-painting-expected.txt:
* platform/qt-5.0/fast/forms/placeholder-pseudo-style-expected.png:
* platform/qt-5.0/fast/forms/placeholder-pseudo-style-expected.txt:
* platform/qt-5.0/fast/forms/search-rtl-expected.png:
* platform/qt-5.0/fast/forms/search-rtl-expected.txt:
* platform/qt-5.0/fast/forms/select-background-none-expected.txt:
* platform/qt-5.0/fast/forms/select-baseline-expected.png:
* platform/qt-5.0/fast/forms/select-baseline-expected.txt:
* platform/qt-5.0/fast/forms/selectlist-minsize-expected.txt:
* platform/qt-5.0/fast/forms/textarea-align-expected.png:
* platform/qt-5.0/fast/forms/textarea-align-expected.txt:
* platform/qt-5.0/fast/forms/textarea-setinnerhtml-expected.png:
* platform/qt-5.0/fast/forms/textarea-setinnerhtml-expected.txt:
* platform/qt/fast/forms/003-expected.txt:
* platform/qt/fast/forms/004-expected.txt:
* platform/qt/fast/forms/006-expected.txt:
* platform/qt/fast/forms/007-expected.txt:
* platform/qt/fast/forms/HTMLOptionElement_label01-expected.txt:
* platform/qt/fast/forms/HTMLOptionElement_label02-expected.txt:
* platform/qt/fast/forms/HTMLOptionElement_label03-expected.txt:
* platform/qt/fast/forms/HTMLOptionElement_label04-expected.txt:
* platform/qt/fast/forms/HTMLOptionElement_label05-expected.txt:
* platform/qt/fast/forms/basic-inputs-expected.png:
* platform/qt/fast/forms/basic-inputs-expected.txt:
* platform/qt/fast/forms/basic-selects-expected.png:
* platform/qt/fast/forms/basic-selects-expected.txt:
* platform/qt/fast/forms/basic-textareas-quirks-expected.png:
* platform/qt/fast/forms/basic-textareas-quirks-expected.txt:
* platform/qt/fast/forms/blankbuttons-expected.png:
* platform/qt/fast/forms/blankbuttons-expected.txt:
* platform/qt/fast/forms/button-align-expected.png:
* platform/qt/fast/forms/button-align-expected.txt:
* platform/qt/fast/forms/button-cannot-be-nested-expected.png:
* platform/qt/fast/forms/button-cannot-be-nested-expected.txt:
* platform/qt/fast/forms/button-default-title-expected.txt:
* platform/qt/fast/forms/button-generated-content-expected.png:
* platform/qt/fast/forms/button-generated-content-expected.txt:
* platform/qt/fast/forms/button-inner-block-reuse-expected.png:
* platform/qt/fast/forms/button-inner-block-reuse-expected.txt:
* platform/qt/fast/forms/button-positioned-expected.png:
* platform/qt/fast/forms/button-positioned-expected.txt:
* platform/qt/fast/forms/button-sizes-expected.png:
* platform/qt/fast/forms/button-sizes-expected.txt:
* platform/qt/fast/forms/button-style-color-expected.png:
* platform/qt/fast/forms/button-style-color-expected.txt:
* platform/qt/fast/forms/button-submit-expected.txt:
* platform/qt/fast/forms/button-table-styles-expected.png:
* platform/qt/fast/forms/button-table-styles-expected.txt:
* platform/qt/fast/forms/button-text-transform-expected.png:
* platform/qt/fast/forms/button-text-transform-expected.txt:
* platform/qt/fast/forms/caret-rtl-expected.txt:
* platform/qt/fast/forms/control-clip-expected.txt:
* platform/qt/fast/forms/control-clip-overflow-expected.png:
* platform/qt/fast/forms/control-clip-overflow-expected.txt:
* platform/qt/fast/forms/control-restrict-line-height-expected.png:
* platform/qt/fast/forms/control-restrict-line-height-expected.txt:
* platform/qt/fast/forms/disabled-select-change-index-expected.png:
* platform/qt/fast/forms/disabled-select-change-index-expected.txt:
* platform/qt/fast/forms/encoding-test-expected.png:
* platform/qt/fast/forms/encoding-test-expected.txt:
* platform/qt/fast/forms/fieldset-align-expected.png:
* platform/qt/fast/forms/fieldset-align-expected.txt:
* platform/qt/fast/forms/fieldset-legend-padding-unclipped-fieldset-border-expected.png:
* platform/qt/fast/forms/fieldset-legend-padding-unclipped-fieldset-border-expected.txt:
* platform/qt/fast/forms/fieldset-with-float-expected.txt:
* platform/qt/fast/forms/file/file-input-direction-expected.png:
* platform/qt/fast/forms/file/file-input-direction-expected.txt:
* platform/qt/fast/forms/file/file-input-disabled-expected.png:
* platform/qt/fast/forms/file/file-input-disabled-expected.txt:
* platform/qt/fast/forms/float-before-fieldset-expected.png:
* platform/qt/fast/forms/float-before-fieldset-expected.txt:
* platform/qt/fast/forms/floating-textfield-relayout-expected.png:
* platform/qt/fast/forms/floating-textfield-relayout-expected.txt:
* platform/qt/fast/forms/form-added-to-table-expected.txt:
* platform/qt/fast/forms/form-hides-table-expected.png:
* platform/qt/fast/forms/form-hides-table-expected.txt:
* platform/qt/fast/forms/form-in-malformed-markup-expected.txt:
* platform/qt/fast/forms/formmove-expected.txt:
* platform/qt/fast/forms/formmove2-expected.txt:
* platform/qt/fast/forms/formmove3-expected.png:
* platform/qt/fast/forms/formmove3-expected.txt:
* platform/qt/fast/forms/hidden-listbox-expected.txt:
* platform/qt/fast/forms/image-border-expected.txt:
* platform/qt/fast/forms/indeterminate-expected.txt:
* platform/qt/fast/forms/input-align-expected.png:
* platform/qt/fast/forms/input-align-expected.txt:
* platform/qt/fast/forms/input-align-image-expected.txt:
* platform/qt/fast/forms/input-appearance-bkcolor-expected.png:
* platform/qt/fast/forms/input-appearance-bkcolor-expected.txt:
* platform/qt/fast/forms/input-appearance-default-bkcolor-expected.png:
* platform/qt/fast/forms/input-appearance-default-bkcolor-expected.txt:
* platform/qt/fast/forms/input-appearance-disabled-expected.png:
* platform/qt/fast/forms/input-appearance-disabled-expected.txt:
* platform/qt/fast/forms/input-appearance-focus-expected.png:
* platform/qt/fast/forms/input-appearance-focus-expected.txt:
* platform/qt/fast/forms/input-appearance-preventDefault-expected.png:
* platform/qt/fast/forms/input-appearance-preventDefault-expected.txt:
* platform/qt/fast/forms/input-appearance-readonly-expected.png:
* platform/qt/fast/forms/input-appearance-readonly-expected.txt:
* platform/qt/fast/forms/input-appearance-selection-expected.png:
* platform/qt/fast/forms/input-appearance-selection-expected.txt:
* platform/qt/fast/forms/input-appearance-visibility-expected.png:
* platform/qt/fast/forms/input-appearance-visibility-expected.txt:
* platform/qt/fast/forms/input-baseline-expected.png:
* platform/qt/fast/forms/input-baseline-expected.txt:
* platform/qt/fast/forms/input-button-sizes-expected.png:
* platform/qt/fast/forms/input-button-sizes-expected.txt:
* platform/qt/fast/forms/input-double-click-selection-gap-bug-expected.png:
* platform/qt/fast/forms/input-double-click-selection-gap-bug-expected.txt:
* platform/qt/fast/forms/input-field-text-truncated-expected.png:
* platform/qt/fast/forms/input-field-text-truncated-expected.txt:
* platform/qt/fast/forms/input-first-letter-expected.txt:
* platform/qt/fast/forms/input-no-renderer-expected.txt:
* platform/qt/fast/forms/input-placeholder-visibility-1-expected.png:
* platform/qt/fast/forms/input-placeholder-visibility-1-expected.txt:
* platform/qt/fast/forms/input-placeholder-visibility-3-expected.png:
* platform/qt/fast/forms/input-placeholder-visibility-3-expected.txt:
* platform/qt/fast/forms/input-readonly-dimmed-expected.png:
* platform/qt/fast/forms/input-readonly-dimmed-expected.txt:
* platform/qt/fast/forms/input-readonly-empty-expected.png:
* platform/qt/fast/forms/input-readonly-empty-expected.txt:
* platform/qt/fast/forms/input-spaces-expected.png:
* platform/qt/fast/forms/input-spaces-expected.txt:
* platform/qt/fast/forms/input-text-click-inside-expected.png:
* platform/qt/fast/forms/input-text-click-inside-expected.txt:
* platform/qt/fast/forms/input-text-double-click-expected.png:
* platform/qt/fast/forms/input-text-double-click-expected.txt:
* platform/qt/fast/forms/input-text-option-delete-expected.png:
* platform/qt/fast/forms/input-text-option-delete-expected.txt:
* platform/qt/fast/forms/input-text-self-emptying-click-expected.png:
* platform/qt/fast/forms/input-text-self-emptying-click-expected.txt:
* platform/qt/fast/forms/input-text-word-wrap-expected.png:
* platform/qt/fast/forms/input-text-word-wrap-expected.txt:
* platform/qt/fast/forms/input-width-expected.png:
* platform/qt/fast/forms/input-width-expected.txt:
* platform/qt/fast/forms/linebox-overflow-in-textarea-padding-expected.txt:
* platform/qt/fast/forms/listbox-scrollbar-incremental-load-expected.txt:
* platform/qt/fast/forms/menulist-clip-expected.png:
* platform/qt/fast/forms/menulist-clip-expected.txt:
* platform/qt/fast/forms/menulist-deselect-update-expected.txt:
* platform/qt/fast/forms/menulist-no-overflow-expected.txt:
* platform/qt/fast/forms/menulist-option-wrap-expected.png:
* platform/qt/fast/forms/menulist-option-wrap-expected.txt:
* platform/qt/fast/forms/menulist-style-color-expected.png:
* platform/qt/fast/forms/menulist-style-color-expected.txt:
* platform/qt/fast/forms/minWidthPercent-expected.png:
* platform/qt/fast/forms/minWidthPercent-expected.txt:
* platform/qt/fast/forms/negativeLineHeight-expected.png:
* platform/qt/fast/forms/negativeLineHeight-expected.txt:
* platform/qt/fast/forms/number/input-appearance-number-rtl-expected.png:
* platform/qt/fast/forms/number/input-appearance-number-rtl-expected.txt:
* platform/qt/fast/forms/number/input-appearance-spinbutton-disabled-readonly-expected.png:
* platform/qt/fast/forms/number/input-appearance-spinbutton-disabled-readonly-expected.txt:
* platform/qt/fast/forms/number/input-appearance-spinbutton-layer-expected.png:
* platform/qt/fast/forms/number/input-appearance-spinbutton-layer-expected.txt:
* platform/qt/fast/forms/option-index-expected.txt:
* platform/qt/fast/forms/option-script-expected.txt:
* platform/qt/fast/forms/option-strip-whitespace-expected.txt:
* platform/qt/fast/forms/option-text-clip-expected.txt:
* platform/qt/fast/forms/placeholder-position-expected.png:
* platform/qt/fast/forms/placeholder-position-expected.txt:
* platform/qt/fast/forms/preserveFormDuringResidualStyle-expected.txt:
* platform/qt/fast/forms/range/input-appearance-range-expected.png:
* platform/qt/fast/forms/range/input-appearance-range-expected.txt:
* platform/qt/fast/forms/range/range-thumb-height-percentage-expected.png:
* platform/qt/fast/forms/range/range-thumb-height-percentage-expected.txt:
* platform/qt/fast/forms/range/slider-padding-expected.png:
* platform/qt/fast/forms/range/slider-padding-expected.txt:
* platform/qt/fast/forms/search-cancel-button-style-sharing-expected.png:
* platform/qt/fast/forms/search-cancel-button-style-sharing-expected.txt:
* platform/qt/fast/forms/search-display-none-cancel-button-expected.png:
* platform/qt/fast/forms/search-display-none-cancel-button-expected.txt:
* platform/qt/fast/forms/search-styled-expected.png:
* platform/qt/fast/forms/search-styled-expected.txt:
* platform/qt/fast/forms/search-vertical-alignment-expected.png:
* platform/qt/fast/forms/search-vertical-alignment-expected.txt:
* platform/qt/fast/forms/select-align-expected.txt:
* platform/qt/fast/forms/select-block-background-expected.txt:
* platform/qt/fast/forms/select-change-listbox-size-expected.txt:
* platform/qt/fast/forms/select-change-listbox-to-popup-expected.txt:
* platform/qt/fast/forms/select-change-popup-to-listbox-expected.txt:
* platform/qt/fast/forms/select-dirty-parent-pref-widths-expected.txt:
* platform/qt/fast/forms/select-disabled-appearance-expected.txt:
* platform/qt/fast/forms/select-display-none-style-resolve-expected.txt:
* platform/qt/fast/forms/select-empty-option-height-expected.txt:
* platform/qt/fast/forms/select-initial-position-expected.txt:
* platform/qt/fast/forms/select-item-background-clip-expected.txt:
* platform/qt/fast/forms/select-list-box-with-height-expected.txt:
* platform/qt/fast/forms/select-listbox-multiple-no-focusring-expected.png:
* platform/qt/fast/forms/select-listbox-multiple-no-focusring-expected.txt:
* platform/qt/fast/forms/select-overflow-scroll-expected.png:
* platform/qt/fast/forms/select-overflow-scroll-expected.txt:
* platform/qt/fast/forms/select-overflow-scroll-inherited-expected.png:
* platform/qt/fast/forms/select-overflow-scroll-inherited-expected.txt:
* platform/qt/fast/forms/select-selected-expected.txt:
* platform/qt/fast/forms/select-size-expected.txt:
* platform/qt/fast/forms/select-style-expected.txt:
* platform/qt/fast/forms/stuff-on-my-optgroup-expected.txt:
* platform/qt/fast/forms/targeted-frame-submission-expected.png:
* platform/qt/fast/forms/targeted-frame-submission-expected.txt:
* platform/qt/fast/forms/text-style-color-expected.png:
* platform/qt/fast/forms/text-style-color-expected.txt:
* platform/qt/fast/forms/textarea-placeholder-pseudo-style-expected.png:
* platform/qt/fast/forms/textarea-placeholder-pseudo-style-expected.txt:
* platform/qt/fast/forms/textarea-placeholder-visibility-1-expected.png:
* platform/qt/fast/forms/textarea-placeholder-visibility-1-expected.txt:
* platform/qt/fast/forms/textarea-placeholder-visibility-2-expected.png:
* platform/qt/fast/forms/textarea-placeholder-visibility-2-expected.txt:
* platform/qt/fast/forms/textarea-scrollbar-expected.png:
* platform/qt/fast/forms/textarea-scrollbar-expected.txt:
* platform/qt/fast/forms/textarea-scrolled-type-expected.png:
* platform/qt/fast/forms/textarea-scrolled-type-expected.txt:
* platform/qt/fast/forms/textfield-focus-ring-expected.png:
* platform/qt/fast/forms/textfield-focus-ring-expected.txt:
* platform/qt/fast/forms/textfield-outline-expected.png:
* platform/qt/fast/forms/textfield-outline-expected.txt:
* platform/qt/fast/forms/textfield-overflow-by-value-update-expected.txt:
* platform/qt/fast/forms/textfield-overflow-expected.png:
* platform/qt/fast/forms/textfield-overflow-expected.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122879 268f45cc-cd09-0410-ab3c-d52691b4dbfc
A couple of UI nits about the flagging feature in results.html
https://bugs.webkit.org/show_bug.cgi?id=86798

Reviewed by Dirk Pranke.

-Clicking the flag unflags it now
-There's a flag all link for each test list
-Make the flag list always show up at the bottom of the viewport
when there are flagged tests. This makes it both less annoying
and easier to understand what's going on when you flag a test.
This required wrapping all the content in a div so that we could
make the body be a flexbox.
* fast/harness/resources/results-test.js:
(runSingleRowTest):
* fast/harness/results.html:

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