| OLD | NEW |
| 1 /** | 1 /** |
| 2 * Copyright (C) 2007 Rob Buis <buis@kde.org> | 2 * Copyright (C) 2007 Rob Buis <buis@kde.org> |
| 3 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org> | 3 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org> |
| 4 * Copyright (C) 2007 Eric Seidel <eric@webkit.org> | 4 * Copyright (C) 2007 Eric Seidel <eric@webkit.org> |
| 5 * Copyright (C) 2009 Google, Inc. All rights reserved. | 5 * Copyright (C) 2009 Google, Inc. All rights reserved. |
| 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 | 26 |
| 27 namespace blink { | 27 namespace blink { |
| 28 | 28 |
| 29 class AffineTransform; | 29 class AffineTransform; |
| 30 class FloatPoint; | 30 class FloatPoint; |
| 31 class FloatRect; | 31 class FloatRect; |
| 32 class GraphicsContext; | 32 class GraphicsContext; |
| 33 class PaintInvalidationState; | 33 class PaintInvalidationState; |
| 34 class LayoutRect; | 34 class LayoutRect; |
| 35 struct PaintInfo; | 35 struct PaintInfo; |
| 36 class Path; |
| 36 class RenderGeometryMap; | 37 class RenderGeometryMap; |
| 37 class RenderLayerModelObject; | 38 class RenderLayerModelObject; |
| 38 class RenderObject; | 39 class RenderObject; |
| 39 class RenderStyle; | 40 class RenderStyle; |
| 40 class RenderSVGRoot; | 41 class RenderSVGRoot; |
| 42 class RenderSVGShape; |
| 41 class StrokeData; | 43 class StrokeData; |
| 42 class TransformState; | 44 class TransformState; |
| 43 | 45 |
| 44 class SVGRenderSupport { | 46 class SVGRenderSupport { |
| 45 public: | 47 public: |
| 46 // Shares child layouting code between RenderSVGRoot/RenderSVG(Hidden)Contai
ner | 48 // Shares child layouting code between RenderSVGRoot/RenderSVG(Hidden)Contai
ner |
| 47 static void layoutChildren(RenderObject*, bool selfNeedsLayout); | 49 static void layoutChildren(RenderObject*, bool selfNeedsLayout); |
| 48 | 50 |
| 49 // Layout resources used by this node. | 51 // Layout resources used by this node. |
| 50 static void layoutResourcesIfNeeded(const RenderObject*); | 52 static void layoutResourcesIfNeeded(const RenderObject*); |
| (...skipping 22 matching lines...) Expand all Loading... |
| 73 // Important functions used by nearly all SVG renderers centralizing coordin
ate transformations / paint invalidation rect calculations | 75 // Important functions used by nearly all SVG renderers centralizing coordin
ate transformations / paint invalidation rect calculations |
| 74 static LayoutRect clippedOverflowRectForPaintInvalidation(const RenderObject
*, const RenderLayerModelObject* paintInvalidationContainer, const PaintInvalida
tionState*); | 76 static LayoutRect clippedOverflowRectForPaintInvalidation(const RenderObject
*, const RenderLayerModelObject* paintInvalidationContainer, const PaintInvalida
tionState*); |
| 75 static void computeFloatRectForPaintInvalidation(const RenderObject*, const
RenderLayerModelObject* paintInvalidationContainer, FloatRect&, const PaintInval
idationState*); | 77 static void computeFloatRectForPaintInvalidation(const RenderObject*, const
RenderLayerModelObject* paintInvalidationContainer, FloatRect&, const PaintInval
idationState*); |
| 76 static void mapLocalToContainer(const RenderObject*, const RenderLayerModelO
bject* paintInvalidationContainer, TransformState&, bool* wasFixed = 0, const Pa
intInvalidationState* = 0); | 78 static void mapLocalToContainer(const RenderObject*, const RenderLayerModelO
bject* paintInvalidationContainer, TransformState&, bool* wasFixed = 0, const Pa
intInvalidationState* = 0); |
| 77 static const RenderObject* pushMappingToContainer(const RenderObject*, const
RenderLayerModelObject* ancestorToStopAt, RenderGeometryMap&); | 79 static const RenderObject* pushMappingToContainer(const RenderObject*, const
RenderLayerModelObject* ancestorToStopAt, RenderGeometryMap&); |
| 78 | 80 |
| 79 // Shared between SVG renderers and resources. | 81 // Shared between SVG renderers and resources. |
| 80 static void applyStrokeStyleToContext(GraphicsContext*, const RenderStyle*,
const RenderObject*); | 82 static void applyStrokeStyleToContext(GraphicsContext*, const RenderStyle*,
const RenderObject*); |
| 81 static void applyStrokeStyleToStrokeData(StrokeData*, const RenderStyle*, co
nst RenderObject*); | 83 static void applyStrokeStyleToStrokeData(StrokeData*, const RenderStyle*, co
nst RenderObject*); |
| 82 | 84 |
| 85 // Fill and/or stroke the primitive provide as either |path| or |shape|. The
former has precedence if both are non-zero. |
| 86 static void fillOrStrokePrimitive(GraphicsContext*, unsigned short resourceM
ode, const Path*, const RenderSVGShape*); |
| 87 |
| 83 // Determines if any ancestor's transform has changed. | 88 // Determines if any ancestor's transform has changed. |
| 84 static bool transformToRootChanged(RenderObject*); | 89 static bool transformToRootChanged(RenderObject*); |
| 85 | 90 |
| 86 // FIXME: These methods do not belong here. | 91 // FIXME: These methods do not belong here. |
| 87 static const RenderSVGRoot* findTreeRootObject(const RenderObject*); | 92 static const RenderSVGRoot* findTreeRootObject(const RenderObject*); |
| 88 | 93 |
| 89 // Helper method for determining if a RenderObject marked as text (isText()=
= true) | 94 // Helper method for determining if a RenderObject marked as text (isText()=
= true) |
| 90 // can/will be rendered as part of a <text>. | 95 // can/will be rendered as part of a <text>. |
| 91 static bool isRenderableTextNode(const RenderObject*); | 96 static bool isRenderableTextNode(const RenderObject*); |
| 92 | 97 |
| 93 private: | 98 private: |
| 94 static void updateObjectBoundingBox(FloatRect& objectBoundingBox, bool& obje
ctBoundingBoxValid, RenderObject* other, FloatRect otherBoundingBox); | 99 static void updateObjectBoundingBox(FloatRect& objectBoundingBox, bool& obje
ctBoundingBoxValid, RenderObject* other, FloatRect otherBoundingBox); |
| 95 static bool layoutSizeOfNearestViewportChanged(const RenderObject* start); | 100 static bool layoutSizeOfNearestViewportChanged(const RenderObject* start); |
| 96 }; | 101 }; |
| 97 | 102 |
| 98 } // namespace blink | 103 } // namespace blink |
| 99 | 104 |
| 100 #endif // SVGRenderSupport_h | 105 #endif // SVGRenderSupport_h |
| OLD | NEW |