Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(463)

Side by Side Diff: Source/core/rendering/svg/SVGRenderTreeAsText.cpp

Issue 23581008: Revert r154797: "Move isValid/isCurrentColor from Color to StyleColor" (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004, 2005, 2007, 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2004, 2005, 2007, 2009 Apple Inc. All rights reserved.
3 * (C) 2005 Rob Buis <buis@kde.org> 3 * (C) 2005 Rob Buis <buis@kde.org>
4 * (C) 2006 Alexander Kellett <lypanov@kde.org> 4 * (C) 2006 Alexander Kellett <lypanov@kde.org>
5 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 5 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
6 * 6 *
7 * Redistribution and use in source and binary forms, with or without 7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions 8 * modification, are permitted provided that the following conditions
9 * are met: 9 * are met:
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 263
264 if (!object.localTransform().isIdentity()) 264 if (!object.localTransform().isIdentity())
265 writeNameValuePair(ts, "transform", object.localTransform()); 265 writeNameValuePair(ts, "transform", object.localTransform());
266 writeIfNotDefault(ts, "image rendering", style->imageRendering(), RenderStyl e::initialImageRendering()); 266 writeIfNotDefault(ts, "image rendering", style->imageRendering(), RenderStyl e::initialImageRendering());
267 writeIfNotDefault(ts, "opacity", style->opacity(), RenderStyle::initialOpaci ty()); 267 writeIfNotDefault(ts, "opacity", style->opacity(), RenderStyle::initialOpaci ty());
268 if (object.isSVGShape()) { 268 if (object.isSVGShape()) {
269 const RenderSVGShape& shape = static_cast<const RenderSVGShape&>(object) ; 269 const RenderSVGShape& shape = static_cast<const RenderSVGShape&>(object) ;
270 ASSERT(shape.node()); 270 ASSERT(shape.node());
271 ASSERT(shape.node()->isSVGElement()); 271 ASSERT(shape.node()->isSVGElement());
272 272
273 StyleColor fallbackColor; 273 Color fallbackColor;
274 if (RenderSVGResource* strokePaintingResource = RenderSVGResource::strok ePaintingResource(const_cast<RenderSVGShape*>(&shape), shape.style(), fallbackCo lor)) { 274 if (RenderSVGResource* strokePaintingResource = RenderSVGResource::strok ePaintingResource(const_cast<RenderSVGShape*>(&shape), shape.style(), fallbackCo lor)) {
275 TextStreamSeparator s(" "); 275 TextStreamSeparator s(" ");
276 ts << " [stroke={" << s; 276 ts << " [stroke={" << s;
277 writeSVGPaintingResource(ts, strokePaintingResource); 277 writeSVGPaintingResource(ts, strokePaintingResource);
278 278
279 SVGLengthContext lengthContext(toSVGElement(shape.node())); 279 SVGLengthContext lengthContext(toSVGElement(shape.node()));
280 double dashOffset = svgStyle->strokeDashOffset().value(lengthContext ); 280 double dashOffset = svgStyle->strokeDashOffset().value(lengthContext );
281 double strokeWidth = svgStyle->strokeWidth().value(lengthContext); 281 double strokeWidth = svgStyle->strokeWidth().value(lengthContext);
282 const Vector<SVGLength>& dashes = svgStyle->strokeDashArray(); 282 const Vector<SVGLength>& dashes = svgStyle->strokeDashArray();
283 283
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after
663 ts << " "; 663 ts << " ";
664 writeNameAndQuotedValue(ts, "filter", svgStyle->filterResource()); 664 writeNameAndQuotedValue(ts, "filter", svgStyle->filterResource());
665 ts << " "; 665 ts << " ";
666 writeStandardPrefix(ts, *filter, 0); 666 writeStandardPrefix(ts, *filter, 0);
667 ts << " " << filter->resourceBoundingBox(&renderer) << "\n"; 667 ts << " " << filter->resourceBoundingBox(&renderer) << "\n";
668 } 668 }
669 } 669 }
670 } 670 }
671 671
672 } // namespace WebCore 672 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698