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

Unified Diff: Source/platform/fonts/shaping/HarfBuzzShaper.h

Issue 1248453004: Change Font::offsetForPositionForComplexText to use CachingWordShapeIterator (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 5 years, 4 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
Index: Source/platform/fonts/shaping/HarfBuzzShaper.h
diff --git a/Source/platform/fonts/shaping/HarfBuzzShaper.h b/Source/platform/fonts/shaping/HarfBuzzShaper.h
index 29cf473532a06de38223598a42640adb35d974d3..36fb2973ffa8e76cdf2e081a3b062624afdf990f 100644
--- a/Source/platform/fonts/shaping/HarfBuzzShaper.h
+++ b/Source/platform/fonts/shaping/HarfBuzzShaper.h
@@ -62,10 +62,11 @@ public:
float width() { return m_width; }
FloatRect bounds() { return m_glyphBoundingBox; }
- int offsetForPosition(float targetX);
unsigned numCharacters() const { return m_numCharacters; }
void fallbackFonts(HashSet<const SimpleFontData*>*) const;
+ static int offsetForPosition(Vector<RefPtr<ShapeResult>>&,
+ const TextRun&, float targetX);
static float fillGlyphBuffer(Vector<RefPtr<ShapeResult>>&,
GlyphBuffer*, const TextRun&, unsigned from, unsigned to);
static float fillGlyphBufferForTextEmphasis(Vector<RefPtr<ShapeResult>>&,
@@ -86,6 +87,7 @@ private:
ShapeResult(const Font*, unsigned numCharacters, TextDirection);
+ int offsetForPosition(float targetX);
template<TextDirection>
float fillGlyphBufferForRun(GlyphBuffer*, const RunInfo*,
float initialAdvance, unsigned from, unsigned to, unsigned runOffset);

Powered by Google App Engine
This is Rietveld 408576698