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

Unified Diff: third_party/WebKit/Source/platform/fonts/shaping/ShapeResult.h

Issue 2739993002: Add ShapeResult::positionForOffset method (Closed)
Patch Set: Created 3 years, 9 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: third_party/WebKit/Source/platform/fonts/shaping/ShapeResult.h
diff --git a/third_party/WebKit/Source/platform/fonts/shaping/ShapeResult.h b/third_party/WebKit/Source/platform/fonts/shaping/ShapeResult.h
index 911cb8a381010a476d5726c95025c50e42b39e4d..49f9502a7f964db0a698aef130d4872228b20a3d 100644
--- a/third_party/WebKit/Source/platform/fonts/shaping/ShapeResult.h
+++ b/third_party/WebKit/Source/platform/fonts/shaping/ShapeResult.h
@@ -75,7 +75,8 @@ class PLATFORM_EXPORT ShapeResult : public RefCounted<ShapeResult> {
// For memory reporting.
size_t byteSize() const;
- int offsetForPosition(float targetX, bool includePartialGlyphs) const;
+ unsigned offsetForPosition(float targetX, bool includePartialGlyphs) const;
+ float positionForOffset(unsigned offset) const;
PassRefPtr<ShapeResult> applySpacingToCopy(ShapeResultSpacing&,
const TextRun&) const;

Powered by Google App Engine
This is Rietveld 408576698