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 { return (fillPaintType() == SVG_PAINTT YPE_CURRENTCOLOR) || (visitedLinkFillPaintType() == SVG_PAINTTYPE_CURRENTCOLOR); } | |
fs
2015/11/20 16:27:14
You need to also check for a currentColor fallback
| |
361 bool isStrokeColorCurrentColor() const { return (strokePaintType() == SVG_PA INTTYPE_CURRENTCOLOR) || (visitedLinkStrokePaintType() == SVG_PAINTTYPE_CURRENTC OLOR); } | |
362 | |
360 // convenience | 363 // convenience |
361 bool hasClipper() const { return !clipperResource().isEmpty(); } | 364 bool hasClipper() const { return !clipperResource().isEmpty(); } |
362 bool hasMasker() const { return !maskerResource().isEmpty(); } | 365 bool hasMasker() const { return !maskerResource().isEmpty(); } |
363 bool hasFilter() const { return !filterResource().isEmpty(); } | 366 bool hasFilter() const { return !filterResource().isEmpty(); } |
364 bool hasMarkers() const { return !markerStartResource().isEmpty() || !marker MidResource().isEmpty() || !markerEndResource().isEmpty(); } | 367 bool hasMarkers() const { return !markerStartResource().isEmpty() || !marker MidResource().isEmpty() || !markerEndResource().isEmpty(); } |
365 bool hasStroke() const { return strokePaintType() != SVG_PAINTTYPE_NONE; } | 368 bool hasStroke() const { return strokePaintType() != SVG_PAINTTYPE_NONE; } |
366 bool hasVisibleStroke() const { return hasStroke() && !strokeWidth().isZero( ); } | 369 bool hasVisibleStroke() const { return hasStroke() && !strokeWidth().isZero( ); } |
367 bool hasSquareCapStyle() const { return capStyle() == SquareCap; } | 370 bool hasSquareCapStyle() const { return capStyle() == SquareCap; } |
368 bool hasMiterJoinStyle() const { return joinStyle() == MiterJoin; } | 371 bool hasMiterJoinStyle() const { return joinStyle() == MiterJoin; } |
369 bool hasFill() const { return fillPaintType() != SVG_PAINTTYPE_NONE; } | 372 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(); | 466 svg_noninherited_flags.f.baselineShift = initialBaselineShift(); |
464 svg_noninherited_flags.f.vectorEffect = initialVectorEffect(); | 467 svg_noninherited_flags.f.vectorEffect = initialVectorEffect(); |
465 svg_noninherited_flags.f.bufferedRendering = initialBufferedRendering(); | 468 svg_noninherited_flags.f.bufferedRendering = initialBufferedRendering(); |
466 svg_noninherited_flags.f.maskType = initialMaskType(); | 469 svg_noninherited_flags.f.maskType = initialMaskType(); |
467 } | 470 } |
468 }; | 471 }; |
469 | 472 |
470 } // namespace blink | 473 } // namespace blink |
471 | 474 |
472 #endif // SVGComputedStyle_h | 475 #endif // SVGComputedStyle_h |
OLD | NEW |