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

Issue 181443002: Use glyph-ids for lookups of SVG font kerning-pairs (Closed)

Created:
6 years, 10 months ago by fs
Modified:
6 years, 9 months ago
CC:
blink-reviews, krit, ed+blinkwatch_opera.com, f(malita), gyuyoung.kim_webkit.org, Stephen Chennney, pdr., rwlbuis
Visibility:
Public.

Description

Use glyph-ids for lookups of SVG font kerning-pairs This CL eliminates the SVGTextMetrics::Glyph class in favor of a simple Glyph (glyph-id). This shrinks SVGTextMetrics objects by two pointers, and avoids the allocation of tiny (often single-character/code-unit) strings. It achieves this by replacing the linear kerning-pair lookup with a table (HashMap) indexed by a key made up of the glyph id's of the two glyphs. Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=168007

Patch Set 1 : Rename SVGGlyphMap::m_namedGlyphs to m_idGlyphs #

Patch Set 2 : Build kerning-tables indexed by glyph-ids. #

Patch Set 3 : Use the kerning-table and drop the old lookup code. #

Patch Set 4 : Fix initialization. #

Patch Set 5 : Vector<...>::append -> Vector<...>::appendVector. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+197 lines, -131 lines) Patch
M Source/core/rendering/svg/SVGTextLayoutEngineSpacing.h View 1 2 2 chunks +2 lines, -2 lines 0 comments Download
M Source/core/rendering/svg/SVGTextLayoutEngineSpacing.cpp View 1 2 2 chunks +12 lines, -9 lines 0 comments Download
M Source/core/rendering/svg/SVGTextMetrics.h View 1 2 3 chunks +4 lines, -14 lines 0 comments Download
M Source/core/rendering/svg/SVGTextMetrics.cpp View 1 2 3 5 chunks +5 lines, -10 lines 0 comments Download
M Source/core/rendering/svg/SVGTextMetricsBuilder.cpp View 1 2 1 chunk +2 lines, -5 lines 0 comments Download
M Source/core/rendering/svg/SVGTextRunRenderingContext.h View 1 2 1 chunk +1 line, -1 line 0 comments Download
M Source/core/rendering/svg/SVGTextRunRenderingContext.cpp View 1 2 1 chunk +2 lines, -2 lines 0 comments Download
M Source/core/svg/SVGFontData.cpp View 1 2 3 chunks +1 line, -4 lines 0 comments Download
M Source/core/svg/SVGFontElement.h View 1 2 3 chunks +10 lines, -5 lines 0 comments Download
M Source/core/svg/SVGFontElement.cpp View 1 2 5 chunks +81 lines, -63 lines 0 comments Download
M Source/core/svg/SVGGlyphMap.h View 1 2 3 4 7 chunks +71 lines, -8 lines 0 comments Download
M Source/platform/fonts/Font.h View 1 2 1 chunk +1 line, -1 line 0 comments Download
M Source/platform/fonts/Font.cpp View 1 2 1 chunk +3 lines, -3 lines 0 comments Download
M Source/platform/fonts/WidthIterator.h View 1 2 2 chunks +0 lines, -3 lines 0 comments Download
M Source/platform/text/TextRun.h View 1 2 2 chunks +2 lines, -1 line 0 comments Download

Messages

Total messages: 6 (0 generated)
fs
Straight from the "Waiting for Godot"-department... While waiting for the demise of SVG fonts, we ...
6 years, 10 months ago (2014-02-26 13:16:47 UTC) #1
Stephen Chennney
I think the trade-offs are worth it. It also makes the code easier to understand, ...
6 years, 10 months ago (2014-02-26 19:52:01 UTC) #2
fs
On 2014/02/26 19:52:01, Stephen Chenney wrote: > I think the trade-offs are worth it. It ...
6 years, 9 months ago (2014-02-27 09:38:24 UTC) #3
fs
The CQ bit was checked by fs@opera.com
6 years, 9 months ago (2014-02-27 09:38:31 UTC) #4
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/fs@opera.com/181443002/80001
6 years, 9 months ago (2014-02-27 09:38:42 UTC) #5
commit-bot: I haz the power
6 years, 9 months ago (2014-02-27 10:28:45 UTC) #6
Message was sent while issue was closed.
Change committed as 168007

Powered by Google App Engine
This is Rietveld 408576698