OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org> | 2 * Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org> |
3 * Copyright (C) 2004, 2005, 2008 Rob Buis <buis@kde.org> | 3 * Copyright (C) 2004, 2005, 2008 Rob Buis <buis@kde.org> |
4 * Copyright (C) 2005, 2007 Eric Seidel <eric@webkit.org> | 4 * Copyright (C) 2005, 2007 Eric Seidel <eric@webkit.org> |
5 * Copyright (C) 2009 Google, Inc. | 5 * Copyright (C) 2009 Google, Inc. |
6 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org> | 6 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org> |
7 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 7 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
8 * Copyright (C) 2009 Jeff Schiller <codedread@gmail.com> | 8 * Copyright (C) 2009 Jeff Schiller <codedread@gmail.com> |
9 * Copyright (C) 2011 Renata Hodovan <reni@webkit.org> | 9 * Copyright (C) 2011 Renata Hodovan <reni@webkit.org> |
10 * Copyright (C) 2011 University of Szeged | 10 * Copyright (C) 2011 University of Szeged |
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
229 GraphicsContextStateSaver stateSaver(*childPaintInfo.context, fa
lse); | 229 GraphicsContextStateSaver stateSaver(*childPaintInfo.context, fa
lse); |
230 if (!SVGRenderSupport::updateGraphicsContext(stateSaver, style()
, *this, ApplyToFillMode)) | 230 if (!SVGRenderSupport::updateGraphicsContext(stateSaver, style()
, *this, ApplyToFillMode)) |
231 break; | 231 break; |
232 fillShape(childPaintInfo.context); | 232 fillShape(childPaintInfo.context); |
233 break; | 233 break; |
234 } | 234 } |
235 case PT_STROKE: | 235 case PT_STROKE: |
236 if (svgStyle.hasVisibleStroke()) { | 236 if (svgStyle.hasVisibleStroke()) { |
237 GraphicsContextStateSaver stateSaver(*childPaintInfo.context
, false); | 237 GraphicsContextStateSaver stateSaver(*childPaintInfo.context
, false); |
238 AffineTransform nonScalingTransform; | 238 AffineTransform nonScalingTransform; |
| 239 const AffineTransform* additionalPaintServerTransform = 0; |
239 | 240 |
240 if (hasNonScalingStroke()) { | 241 if (hasNonScalingStroke()) { |
241 AffineTransform nonScalingTransform = nonScalingStrokeTr
ansform(); | 242 nonScalingTransform = nonScalingStrokeTransform(); |
242 if (!setupNonScalingStrokeContext(nonScalingTransform, s
tateSaver)) | 243 if (!setupNonScalingStrokeContext(nonScalingTransform, s
tateSaver)) |
243 return; | 244 return; |
| 245 |
| 246 // Non-scaling stroke needs to reset the transform back
to the host transform. |
| 247 additionalPaintServerTransform = &nonScalingTransform; |
244 } | 248 } |
245 | 249 |
246 if (!SVGRenderSupport::updateGraphicsContext(stateSaver, sty
le(), *this, ApplyToStrokeMode)) | 250 if (!SVGRenderSupport::updateGraphicsContext(stateSaver, sty
le(), *this, ApplyToStrokeMode, additionalPaintServerTransform)) |
247 break; | 251 break; |
248 strokeShape(childPaintInfo.context); | 252 strokeShape(childPaintInfo.context); |
249 } | 253 } |
250 break; | 254 break; |
251 case PT_MARKERS: | 255 case PT_MARKERS: |
252 if (!m_markerPositions.isEmpty()) | 256 if (!m_markerPositions.isEmpty()) |
253 drawMarkers(childPaintInfo); | 257 drawMarkers(childPaintInfo); |
254 break; | 258 break; |
255 default: | 259 default: |
256 ASSERT_NOT_REACHED(); | 260 ASSERT_NOT_REACHED(); |
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
433 ASSERT(resources); | 437 ASSERT(resources); |
434 | 438 |
435 RenderSVGResourceMarker* markerStart = resources->markerStart(); | 439 RenderSVGResourceMarker* markerStart = resources->markerStart(); |
436 | 440 |
437 SVGMarkerData markerData(m_markerPositions, markerStart ? markerStart->orien
tType() == SVGMarkerOrientAutoStartReverse : false); | 441 SVGMarkerData markerData(m_markerPositions, markerStart ? markerStart->orien
tType() == SVGMarkerOrientAutoStartReverse : false); |
438 m_path->apply(&markerData, SVGMarkerData::updateFromPathElement); | 442 m_path->apply(&markerData, SVGMarkerData::updateFromPathElement); |
439 markerData.pathIsDone(); | 443 markerData.pathIsDone(); |
440 } | 444 } |
441 | 445 |
442 } | 446 } |
OLD | NEW |