Changeset 66187 in webkit


Ignore:
Timestamp:
Aug 27, 2010 1:08:13 AM (14 years ago)
Author:
Nikolas Zimmermann
Message:

2010-08-27 Nikolas Zimmermann <nzimmermann@rim.com>

Reviewed by Dirk Schulze.

SVGLocatable.getScreenCTM ignores scrolling
https://bugs.webkit.org/show_bug.cgi?id=44083

getScreenCTM needs to include the FrameViews scrollOffset in the e/f parameters of the AffineTransform.
Adding three new tests, which cover scrolling & getScreenCTM in large svgs with scrollbars, and with (nested) divs in overflow="scroll" mode.

Tests: svg/custom/getscreenctm-in-scrollable-div-area-nested.xhtml

svg/custom/getscreenctm-in-scrollable-div-area.xhtml
svg/custom/getscreenctm-in-scrollable-svg-area.xhtml

  • svg/SVGSVGElement.cpp: (WebCore::SVGSVGElement::localCoordinateSpaceTransform):

2010-08-27 Nikolas Zimmermann <nzimmermann@rim.com>

Reviewed by Dirk Schulze.

SVGLocatable.getScreenCTM ignores scrolling
https://bugs.webkit.org/show_bug.cgi?id=44083

  • platform/mac/svg/custom/getscreenctm-in-scrollable-div-area-expected.checksum: Added.
  • platform/mac/svg/custom/getscreenctm-in-scrollable-div-area-expected.png: Added.
  • platform/mac/svg/custom/getscreenctm-in-scrollable-div-area-expected.txt: Added.
  • platform/mac/svg/custom/getscreenctm-in-scrollable-div-area-nested-expected.checksum: Added.
  • platform/mac/svg/custom/getscreenctm-in-scrollable-div-area-nested-expected.png: Added.
  • platform/mac/svg/custom/getscreenctm-in-scrollable-div-area-nested-expected.txt: Added.
  • platform/mac/svg/custom/getscreenctm-in-scrollable-svg-area-expected.checksum: Added.
  • platform/mac/svg/custom/getscreenctm-in-scrollable-svg-area-expected.png: Added.
  • platform/mac/svg/custom/getscreenctm-in-scrollable-svg-area-expected.txt: Added.
  • svg/custom/getscreenctm-in-scrollable-div-area-nested.xhtml: Added.
  • svg/custom/getscreenctm-in-scrollable-div-area.xhtml: Added.
  • svg/custom/getscreenctm-in-scrollable-svg-area.xhtml: Added.
Location:
trunk
Files:
12 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r66184 r66187  
     12010-08-27  Nikolas Zimmermann  <nzimmermann@rim.com>
     2
     3        Reviewed by Dirk Schulze.
     4
     5        SVGLocatable.getScreenCTM ignores scrolling
     6        https://bugs.webkit.org/show_bug.cgi?id=44083
     7
     8        * platform/mac/svg/custom/getscreenctm-in-scrollable-div-area-expected.checksum: Added.
     9        * platform/mac/svg/custom/getscreenctm-in-scrollable-div-area-expected.png: Added.
     10        * platform/mac/svg/custom/getscreenctm-in-scrollable-div-area-expected.txt: Added.
     11        * platform/mac/svg/custom/getscreenctm-in-scrollable-div-area-nested-expected.checksum: Added.
     12        * platform/mac/svg/custom/getscreenctm-in-scrollable-div-area-nested-expected.png: Added.
     13        * platform/mac/svg/custom/getscreenctm-in-scrollable-div-area-nested-expected.txt: Added.
     14        * platform/mac/svg/custom/getscreenctm-in-scrollable-svg-area-expected.checksum: Added.
     15        * platform/mac/svg/custom/getscreenctm-in-scrollable-svg-area-expected.png: Added.
     16        * platform/mac/svg/custom/getscreenctm-in-scrollable-svg-area-expected.txt: Added.
     17        * svg/custom/getscreenctm-in-scrollable-div-area-nested.xhtml: Added.
     18        * svg/custom/getscreenctm-in-scrollable-div-area.xhtml: Added.
     19        * svg/custom/getscreenctm-in-scrollable-svg-area.xhtml: Added.
     20
    1212010-08-26  Philippe Normand  <pnormand@igalia.com>
    222
  • trunk/WebCore/ChangeLog

    r66186 r66187  
     12010-08-27  Nikolas Zimmermann  <nzimmermann@rim.com>
     2
     3        Reviewed by Dirk Schulze.
     4
     5        SVGLocatable.getScreenCTM ignores scrolling
     6        https://bugs.webkit.org/show_bug.cgi?id=44083
     7
     8        getScreenCTM needs to include the FrameViews scrollOffset in the e/f parameters of the AffineTransform.
     9        Adding three new tests, which cover scrolling & getScreenCTM in large svgs with scrollbars, and with (nested) divs in overflow="scroll" mode.
     10
     11        Tests: svg/custom/getscreenctm-in-scrollable-div-area-nested.xhtml
     12               svg/custom/getscreenctm-in-scrollable-div-area.xhtml
     13               svg/custom/getscreenctm-in-scrollable-svg-area.xhtml
     14
     15        * svg/SVGSVGElement.cpp:
     16        (WebCore::SVGSVGElement::localCoordinateSpaceTransform):
     17
    1182010-08-25  Ryosuke Niwa  <rniwa@webkit.org>
    219
  • trunk/WebCore/svg/SVGSVGElement.cpp

    r65665 r66187  
    473473            // also takes the viewBoxToViewTransform() into account, so we have to subtract it here (original cause of bug #27183)
    474474            transform.translate(location.x() - viewBoxTransform.e(), location.y() - viewBoxTransform.f());
     475
     476            // Respect scroll offset.
     477            if (FrameView* view = document()->view()) {
     478                IntSize scrollOffset = view->scrollOffset();
     479                transform.translate(-scrollOffset.width(), -scrollOffset.height());
     480            }
    475481        }
    476482    }
Note: See TracChangeset for help on using the changeset viewer.