[webkit-changes] cvs commit: WebCore/ksvg2/svg SVGRectElementImpl.cpp

Eric eseidel at opensource.apple.com
Thu Dec 29 19:23:52 PST 2005


eseidel     05/12/29 19:23:52

  Modified:    .        ChangeLog
               ksvg2/svg SVGRectElementImpl.cpp
  Log:
  Bug #: 6157
  Submitted by: rob buis
  Reviewed by: eseidel
          WebCore+SVG has some problems with rounded rectangles
          http://bugzilla.opendarwin.org/show_bug.cgi?id=6157
  
          * ksvg2/svg/SVGRectElementImpl.cpp:
          (SVGRectElementImpl::toPathData): fixed round rect calculations
  
  Revision  Changes    Path
  1.56      +10 -0     WebCore/ChangeLog
  
  Index: ChangeLog
  ===================================================================
  RCS file: /cvs/root/WebCore/ChangeLog,v
  retrieving revision 1.55
  retrieving revision 1.56
  diff -u -r1.55 -r1.56
  --- ChangeLog	29 Dec 2005 23:49:03 -0000	1.55
  +++ ChangeLog	30 Dec 2005 03:23:51 -0000	1.56
  @@ -1,3 +1,13 @@
  +2005-12-29  Rob Buis  <rwlbuis at xs4all.nl>
  +
  +        Reviewed by eseidel.
  +
  +        WebCore+SVG has some problems with rounded rectangles
  +        http://bugzilla.opendarwin.org/show_bug.cgi?id=6157
  +
  +        * ksvg2/svg/SVGRectElementImpl.cpp:
  +        (SVGRectElementImpl::toPathData): fixed round rect calculations
  +
   2005-12-29  Mark Rowe  <opendarwin.org at bdash.net.nz>
   
           Reviewed by eseidel, ggaren, darin.
  
  
  
  1.10      +5 -2      WebCore/ksvg2/svg/SVGRectElementImpl.cpp
  
  Index: SVGRectElementImpl.cpp
  ===================================================================
  RCS file: /cvs/root/WebCore/ksvg2/svg/SVGRectElementImpl.cpp,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- SVGRectElementImpl.cpp	6 Dec 2005 01:23:25 -0000	1.9
  +++ SVGRectElementImpl.cpp	30 Dec 2005 03:23:52 -0000	1.10
  @@ -105,9 +105,12 @@
       float _x = x()->baseVal()->value(), _y = y()->baseVal()->value();
       float _width = width()->baseVal()->value(), _height = height()->baseVal()->value();
   
  -    if(hasAttribute(KDOM::DOMString("rx").impl()) || hasAttribute(KDOM::DOMString("ry").impl()))
  +    bool hasRx = hasAttribute(KDOM::DOMString("rx").impl());
  +    bool hasRy = hasAttribute(KDOM::DOMString("ry").impl());
  +    if(hasRx || hasRy)
       {
  -        float _rx = rx()->baseVal()->value(), _ry = rx()->baseVal()->value();
  +        float _rx = hasRx ? rx()->baseVal()->value() : ry()->baseVal()->value();
  +        float _ry = hasRy ? ry()->baseVal()->value() : rx()->baseVal()->value();
           return KCanvasCreator::self()->createRoundedRectangle(_x, _y, _width, _height, _rx, _ry);
       }
   
  
  
  



More information about the webkit-changes mailing list