diff options
author | djsollen@google.com <djsollen@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2013-10-03 14:42:24 +0000 |
---|---|---|
committer | djsollen@google.com <djsollen@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2013-10-03 14:42:24 +0000 |
commit | 5df5e6126d43f65d47092d682e7a7dd64a77ace3 (patch) | |
tree | 5c7f15ec2403cce693e3a0f850f3b1f78059e051 /include | |
parent | b0a0589f8ac0254ec1beba9db2fc32a2bedb31e5 (diff) |
Update PDF backend to support fallback fonts on Android.
R=edisonn@google.com, reed@google.com, vandebo@chromium.org
Review URL: https://codereview.chromium.org/24364008
git-svn-id: http://skia.googlecode.com/svn/trunk@11586 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'include')
-rw-r--r-- | include/ports/SkTypeface_android.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/include/ports/SkTypeface_android.h b/include/ports/SkTypeface_android.h index 1ee923c4e6..2166e08394 100644 --- a/include/ports/SkTypeface_android.h +++ b/include/ports/SkTypeface_android.h @@ -68,6 +68,22 @@ SK_API void SkUseTestFontConfigFile(const char* mainconf, const char* fallbackco SkTypeface* SkAndroidNextLogicalTypeface(SkFontID currFontID, SkFontID origFontID, const SkPaintOptionsAndroid& options); +/** + * Given a glyphID (built using fallback font chaining) and its origin typeface + * return the actual typeface within the fallback chain that this glyphID + * resolves to. If no suitable typeface is found then NULL is returned. However, + * if returned typeface is not NULL it is assumed to be globally cached so the + * caller need not ref it. + * + * Optionally, if lower/upper bound params are provided and the returned + * typeface is not NULL, then these params are populated with the range of + * glyphIDs that this typeface is capable of resolving. The lower bound is + * inclusive while the upper bound is exclusive. + */ +SkTypeface* SkGetTypefaceForGlyphID(uint16_t glyphID, const SkTypeface* origTypeface, + const SkPaintOptionsAndroid& options, + int* lowerBounds = NULL, int* upperBounds = NULL); + #endif // #ifdef SK_BUILD_FOR_ANDROID #ifdef SK_BUILD_FOR_ANDROID_FRAMEWORK |