Chromium Code Reviews| 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 2004, 2005 Rob Buis <buis@kde.org> | 3 2004, 2005 Rob Buis <buis@kde.org> |
| 4 Copyright (C) 2005, 2006 Apple Computer, Inc. | 4 Copyright (C) 2005, 2006 Apple Computer, Inc. |
| 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 This library is free software; you can redistribute it and/or | 7 This library is free software; you can redistribute it and/or |
| 8 modify it under the terms of the GNU Library General Public | 8 modify it under the terms of the GNU Library General Public |
| 9 License as published by the Free Software Foundation; either | 9 License as published by the Free Software Foundation; either |
| 10 version 2 of the License, or (at your option) any later version. | 10 version 2 of the License, or (at your option) any later version. |
| (...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 350 EPaintOrder paintOrder() const { return (EPaintOrder) svg_inherited_flags.pa intOrder; } | 350 EPaintOrder paintOrder() const { return (EPaintOrder) svg_inherited_flags.pa intOrder; } |
| 351 EPaintOrderType paintOrderType(unsigned index) const; | 351 EPaintOrderType paintOrderType(unsigned index) const; |
| 352 | 352 |
| 353 const SVGPaintType& visitedLinkFillPaintType() const { return fill->visitedL inkPaintType; } | 353 const SVGPaintType& visitedLinkFillPaintType() const { return fill->visitedL inkPaintType; } |
| 354 const Color& visitedLinkFillPaintColor() const { return fill->visitedLinkPai ntColor; } | 354 const Color& visitedLinkFillPaintColor() const { return fill->visitedLinkPai ntColor; } |
| 355 const String& visitedLinkFillPaintUri() const { return fill->visitedLinkPain tUri; } | 355 const String& visitedLinkFillPaintUri() const { return fill->visitedLinkPain tUri; } |
| 356 const SVGPaintType& visitedLinkStrokePaintType() const { return stroke->visi tedLinkPaintType; } | 356 const SVGPaintType& visitedLinkStrokePaintType() const { return stroke->visi tedLinkPaintType; } |
| 357 const Color& visitedLinkStrokePaintColor() const { return stroke->visitedLin kPaintColor; } | 357 const Color& visitedLinkStrokePaintColor() const { return stroke->visitedLin kPaintColor; } |
| 358 const String& visitedLinkStrokePaintUri() const { return stroke->visitedLink PaintUri; } | 358 const String& visitedLinkStrokePaintUri() const { return stroke->visitedLink PaintUri; } |
| 359 | 359 |
| 360 bool isFillColorCurrentColor() const | |
| 361 { | |
| 362 return (fillPaintType() == SVG_PAINTTYPE_CURRENTCOLOR) | |
|
fs
2015/11/25 17:23:00
Drop the redundant ().
| |
| 363 || (visitedLinkFillPaintType() == SVG_PAINTTYPE_CURRENTCOLOR) | |
| 364 || (fillPaintType() == SVG_PAINTTYPE_URI_CURRENTCOLOR) | |
| 365 || (visitedLinkFillPaintType() == SVG_PAINTTYPE_URI_CURRENTCOLOR); | |
| 366 } | |
| 367 | |
| 368 bool isStrokeColorCurrentColor() const | |
| 369 { | |
| 370 return (strokePaintType() == SVG_PAINTTYPE_CURRENTCOLOR) | |
|
fs
2015/11/25 17:23:00
Drop () (like above)
| |
| 371 || (visitedLinkStrokePaintType() == SVG_PAINTTYPE_CURRENTCOLOR) | |
| 372 || (strokePaintType() == SVG_PAINTTYPE_URI_CURRENTCOLOR) | |
| 373 || (visitedLinkStrokePaintType() == SVG_PAINTTYPE_URI_CURRENTCOLOR); | |
| 374 } | |
| 375 | |
| 360 // convenience | 376 // convenience |
| 361 bool hasClipper() const { return !clipperResource().isEmpty(); } | 377 bool hasClipper() const { return !clipperResource().isEmpty(); } |
| 362 bool hasMasker() const { return !maskerResource().isEmpty(); } | 378 bool hasMasker() const { return !maskerResource().isEmpty(); } |
| 363 bool hasFilter() const { return !filterResource().isEmpty(); } | 379 bool hasFilter() const { return !filterResource().isEmpty(); } |
| 364 bool hasMarkers() const { return !markerStartResource().isEmpty() || !marker MidResource().isEmpty() || !markerEndResource().isEmpty(); } | 380 bool hasMarkers() const { return !markerStartResource().isEmpty() || !marker MidResource().isEmpty() || !markerEndResource().isEmpty(); } |
| 365 bool hasStroke() const { return strokePaintType() != SVG_PAINTTYPE_NONE; } | 381 bool hasStroke() const { return strokePaintType() != SVG_PAINTTYPE_NONE; } |
| 366 bool hasVisibleStroke() const { return hasStroke() && !strokeWidth().isZero( ); } | 382 bool hasVisibleStroke() const { return hasStroke() && !strokeWidth().isZero( ); } |
| 367 bool hasSquareCapStyle() const { return capStyle() == SquareCap; } | 383 bool hasSquareCapStyle() const { return capStyle() == SquareCap; } |
| 368 bool hasMiterJoinStyle() const { return joinStyle() == MiterJoin; } | 384 bool hasMiterJoinStyle() const { return joinStyle() == MiterJoin; } |
| 369 bool hasFill() const { return fillPaintType() != SVG_PAINTTYPE_NONE; } | 385 bool hasFill() const { return fillPaintType() != SVG_PAINTTYPE_NONE; } |
| (...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 463 svg_noninherited_flags.f.baselineShift = initialBaselineShift(); | 479 svg_noninherited_flags.f.baselineShift = initialBaselineShift(); |
| 464 svg_noninherited_flags.f.vectorEffect = initialVectorEffect(); | 480 svg_noninherited_flags.f.vectorEffect = initialVectorEffect(); |
| 465 svg_noninherited_flags.f.bufferedRendering = initialBufferedRendering(); | 481 svg_noninherited_flags.f.bufferedRendering = initialBufferedRendering(); |
| 466 svg_noninherited_flags.f.maskType = initialMaskType(); | 482 svg_noninherited_flags.f.maskType = initialMaskType(); |
| 467 } | 483 } |
| 468 }; | 484 }; |
| 469 | 485 |
| 470 } // namespace blink | 486 } // namespace blink |
| 471 | 487 |
| 472 #endif // SVGComputedStyle_h | 488 #endif // SVGComputedStyle_h |
| OLD | NEW |