Changeset 39080 in webkit
- Timestamp:
- Dec 7, 2008 1:23:17 AM (15 years ago)
- Location:
- trunk
- Files:
-
- 3 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r39079 r39080 1 2008-12-07 Dirk Schulze <krit@webkit.org> 2 3 Reviewed by Oliver Hunt. 4 5 Tests strokeRect with patterns and gradients. 6 7 * fast/canvas/canvas-strokeRect-expected.txt: Added. 8 * fast/canvas/canvas-strokeRect.html: Added. 9 * fast/canvas/resources/canvas-strokeRect.js: Added. 10 1 11 2008-12-06 Dirk Schulze <krit@webkit.org> 2 12 -
trunk/WebCore/ChangeLog
r39079 r39080 1 2008-12-07 Dirk Schulze <krit@webkit.org> 2 3 Reviewed by Oliver Hunt. 4 5 Add gradient and pattern support for strokeRect on canvas/Cg. 6 7 Canvas strokeRect() doesn't support gradients 8 https://bugs.webkit.org/show_bug.cgi?id=19790 9 10 Test: fast/canvas/canvas-strokeRect.html 11 12 * platform/graphics/cg/GraphicsContextCG.cpp: 13 (WebCore::GraphicsContext::strokeRect): 14 1 15 2008-12-06 Dirk Schulze <krit@webkit.org> 2 16 -
trunk/WebCore/platform/graphics/cg/GraphicsContextCG.cpp
r38405 r39080 763 763 if (paintingDisabled()) 764 764 return; 765 CGContextStrokeRectWithWidth(platformContext(), r, lineWidth); 765 766 CGContextRef context = platformContext(); 767 switch (m_common->state.strokeColorSpace) { 768 case SolidColorSpace: 769 if (strokeColor().alpha()) 770 CGContextStrokeRectWithWidth(context, r, lineWidth); 771 break; 772 case PatternColorSpace: 773 applyStrokePattern(this, m_common->state.strokePattern.get()); 774 CGContextStrokeRectWithWidth(context, r, lineWidth); 775 break; 776 case GradientColorSpace: 777 CGContextSaveGState(context); 778 setStrokeThickness(lineWidth); 779 CGContextAddRect(context, r); 780 CGContextReplacePathWithStrokedPath(context); 781 CGContextClip(context); 782 CGContextDrawShading(context, m_common->state.strokeGradient->platformGradient()); 783 CGContextRestoreGState(context); 784 break; 785 } 766 786 } 767 787
Note: See TracChangeset
for help on using the changeset viewer.