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

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

Issue 11845002: Merge 138316 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1364/
Patch Set: Created 7 years, 11 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 | « Source/WebCore/rendering/svg/SVGTextMetricsBuilder.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/svg/SVGFontData.cpp
===================================================================
--- Source/WebCore/svg/SVGFontData.cpp (revision 139386)
+++ Source/WebCore/svg/SVGFontData.cpp (working copy)
@@ -189,6 +189,16 @@
size_t glyphsSize = glyphs.size();
for (size_t i = 0; i < glyphsSize; ++i)
glyphs[i].unicodeStringLength = run.length();
+
+ // Do not check alt glyphs for compatibility. Just return the first one.
+ // Later code will fail if we do not do this and the glyph is incompatible.
+ if (glyphsSize) {
+ SVGGlyph& svgGlyph = glyphs[0];
+ iterator.setLastGlyphName(svgGlyph.glyphName);
+ glyphData.glyph = svgGlyph.tableEntry;
+ advanceLength = svgGlyph.unicodeStringLength;
+ return true;
+ }
} else
associatedFontElement->collectGlyphsForString(remainingTextInRun, glyphs);
« no previous file with comments | « Source/WebCore/rendering/svg/SVGTextMetricsBuilder.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698