diff options
author | fmalita <fmalita@chromium.org> | 2014-08-26 07:56:44 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-08-26 07:56:44 -0700 |
commit | b7425173f96e93b090787e2386ba5f022b6c2869 (patch) | |
tree | b73511cfeb4373c7a46a2507ada4274ca4b099e8 /include/core/SkTextBlob.h | |
parent | 3d2e50d1aa56d7f65a4c52fa03af4413fa4c616a (diff) |
SkTextBlob plumbing
Add SkTextBlob serialization + drawTextBlob() overrides.
R=mtklein@google.com, reed@google.com, robertphillips@google.com
BUG=269080
Author: fmalita@chromium.org
Review URL: https://codereview.chromium.org/499413002
Diffstat (limited to 'include/core/SkTextBlob.h')
-rw-r--r-- | include/core/SkTextBlob.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/core/SkTextBlob.h b/include/core/SkTextBlob.h index fcf1766c3e..af29933b4f 100644 --- a/include/core/SkTextBlob.h +++ b/include/core/SkTextBlob.h @@ -13,6 +13,9 @@ #include "SkTArray.h" #include "SkTDArray.h" +class SkReadBuffer; +class SkWriteBuffer; + /** \class SkTextBlob SkTextBlob combines multiple text runs into an immutable, ref-counted structure. @@ -67,7 +70,13 @@ private: SkTextBlob(uint16_t* glyphs, SkScalar* pos, const SkTArray<Run>* runs, const SkRect& bounds); + void flatten(SkWriteBuffer&) const; + static const SkTextBlob* CreateFromBuffer(SkReadBuffer&); + + static unsigned ScalarsPerGlyph(GlyphPositioning pos); + friend class SkCanvas; + friend class SkPictureData; friend class SkTextBlobBuilder; friend class TextBlobTester; |