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

Unified Diff: Source/core/svg/SVGFontData.cpp

Issue 244253003: SimpleFontData::fillGlyphPage should not set zero for missing glyphs (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: fix expectation Created 6 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/svg/custom/svg-fonts-segmented.xhtml ('k') | Source/platform/fonts/GlyphPageTreeNode.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/svg/SVGFontData.cpp
diff --git a/Source/core/svg/SVGFontData.cpp b/Source/core/svg/SVGFontData.cpp
index 2e53d4cb98e64c203e5cef0198483057960a4f61..7cf80284834cad87eeb0fd06c9a701eaa3b2cd37 100644
--- a/Source/core/svg/SVGFontData.cpp
+++ b/Source/core/svg/SVGFontData.cpp
@@ -256,10 +256,8 @@ bool SVGFontData::fillBMPGlyphs(SVGFontElement* fontElement, GlyphPage* pageToFi
for (unsigned i = 0; i < length; ++i) {
String lookupString(buffer + i, 1);
fontElement->collectGlyphsForString(lookupString, glyphs);
- if (glyphs.isEmpty()) {
- pageToFill->setGlyphDataForIndex(offset + i, 0, 0);
+ if (glyphs.isEmpty())
continue;
- }
// Associate entry in glyph page with first valid SVGGlyph.
// If there are multiple valid ones, just take the first one. WidthIterator will take
@@ -281,10 +279,8 @@ bool SVGFontData::fillNonBMPGlyphs(SVGFontElement* fontElement, GlyphPage* pageT
// Each character here consists of a surrogate pair
String lookupString(buffer + i * 2, 2);
fontElement->collectGlyphsForString(lookupString, glyphs);
- if (glyphs.isEmpty()) {
- pageToFill->setGlyphDataForIndex(offset + i, 0, 0);
+ if (glyphs.isEmpty())
continue;
- }
// Associate entry in glyph page with first valid SVGGlyph.
// If there are multiple valid ones, just take the first one. WidthIterator will take
« no previous file with comments | « LayoutTests/svg/custom/svg-fonts-segmented.xhtml ('k') | Source/platform/fonts/GlyphPageTreeNode.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698