| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007, 2008 Nikolas Zimmermann <zimmermann@kde.org> | 2 * Copyright (C) 2007, 2008 Nikolas Zimmermann <zimmermann@kde.org> |
| 3 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. | 3 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. |
| 4 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| (...skipping 28 matching lines...) Expand all Loading... |
| 39 | 39 |
| 40 static inline const SVGFontData* svgFontAndFontFaceElementForFontData(const Simp
leFontData* fontData, SVGFontFaceElement*& fontFace, SVGFontElement*& font) | 40 static inline const SVGFontData* svgFontAndFontFaceElementForFontData(const Simp
leFontData* fontData, SVGFontFaceElement*& fontFace, SVGFontElement*& font) |
| 41 { | 41 { |
| 42 ASSERT(fontData); | 42 ASSERT(fontData); |
| 43 ASSERT(fontData->isCustomFont()); | 43 ASSERT(fontData->isCustomFont()); |
| 44 ASSERT(fontData->isSVGFont()); | 44 ASSERT(fontData->isSVGFont()); |
| 45 | 45 |
| 46 RefPtr<CustomFontData> customFontData = fontData->customFontData(); | 46 RefPtr<CustomFontData> customFontData = fontData->customFontData(); |
| 47 const SVGFontData* svgFontData = static_cast<const SVGFontData*>(customFontD
ata.get()); | 47 const SVGFontData* svgFontData = static_cast<const SVGFontData*>(customFontD
ata.get()); |
| 48 | 48 |
| 49 // FIXME crbug.com/359380 : The current editing impl references the font aft
er the svg font nodes are removed. |
| 50 if (svgFontData->shouldSkipDrawing()) |
| 51 return 0; |
| 52 |
| 49 fontFace = svgFontData->svgFontFaceElement(); | 53 fontFace = svgFontData->svgFontFaceElement(); |
| 50 ASSERT(fontFace); | 54 ASSERT(fontFace); |
| 51 | 55 |
| 52 font = fontFace->associatedFontElement(); | 56 font = fontFace->associatedFontElement(); |
| 53 return svgFontData; | 57 return svgFontData; |
| 54 } | 58 } |
| 55 | 59 |
| 56 static inline RenderObject* firstParentRendererForNonTextNode(RenderObject* rend
erer) | 60 static inline RenderObject* firstParentRendererForNonTextNode(RenderObject* rend
erer) |
| 57 { | 61 { |
| 58 ASSERT(renderer); | 62 ASSERT(renderer); |
| (...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 239 // Restore original state of the SVG Font glyph table and the current font f
allback list, | 243 // Restore original state of the SVG Font glyph table and the current font f
allback list, |
| 240 // to assure the next lookup of the same glyph won't immediately return the
fallback glyph. | 244 // to assure the next lookup of the same glyph won't immediately return the
fallback glyph. |
| 241 page->setGlyphDataForCharacter(character, glyphData.glyph, originalFontData)
; | 245 page->setGlyphDataForCharacter(character, glyphData.glyph, originalFontData)
; |
| 242 ASSERT(fallbackGlyphData.fontData); | 246 ASSERT(fallbackGlyphData.fontData); |
| 243 return fallbackGlyphData; | 247 return fallbackGlyphData; |
| 244 } | 248 } |
| 245 | 249 |
| 246 } | 250 } |
| 247 | 251 |
| 248 #endif | 252 #endif |
| OLD | NEW |