Move glyph cache and descriptor functions off of SkPaint

BUG=skia:7515

Change-Id: If17b157db1077a9a3c0f9efd03929f62a3486419
Reviewed-on: https://skia-review.googlesource.com/98841
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Herb Derby <herb@google.com>
diff --git a/include/core/SkPaint.h b/include/core/SkPaint.h
index 5e5240a..530b3d4 100644
--- a/include/core/SkPaint.h
+++ b/include/core/SkPaint.h
@@ -30,13 +30,11 @@
 class SkPath;
 class SkPathEffect;
 struct SkPoint;
-struct SkScalerContextEffects;
 class SkShader;
 class SkSurfaceProps;
 class SkTextBlob;
 class SkTypeface;
 
-
 /** \class SkPaint
     SkPaint controls options applied when drawing and measuring. SkPaint collects all
     options outside of the SkCanvas clip and SkCanvas matrix.
@@ -1680,20 +1678,6 @@
     SkScalar measure_text(SkGlyphCache*, const char* text, size_t length,
                           int* count, SkRect* bounds) const;
 
-    void getScalerContextDescriptor(SkScalerContextEffects*, SkAutoDescriptor*,
-                                    const SkSurfaceProps* surfaceProps,
-                                    uint32_t scalerContextFlags, const SkMatrix*) const;
-
-    SkGlyphCache* detachCache(const SkSurfaceProps* surfaceProps,
-                              uint32_t scalerContextFlags,
-                              const SkMatrix*) const;
-
-    void descriptorProc(const SkSurfaceProps* surfaceProps, uint32_t scalerContextFlags,
-                        const SkMatrix* deviceMatrix,
-                        void (*proc)(SkTypeface*, const SkScalerContextEffects&,
-                                     const SkDescriptor*, void*),
-                        void* context) const;
-
     /*
      * The luminance color is used to determine which Gamma Canonical color to map to.  This is
      * really only used by backends which want to cache glyph masks, and need some way to know if
@@ -1728,20 +1712,20 @@
 
     static SkScalar MaxCacheSize2(SkScalar maxLimit);
 
+    friend class GrAtlasTextBlob;
+    friend class GrAtlasTextContext;
+    friend class GrGLPathRendering;
+    friend class GrPathRendering;
+    friend class GrStencilAndCoverTextContext;
+    friend class GrTextUtils;
     friend class SkAutoGlyphCache;
     friend class SkAutoGlyphCacheNoGamma;
+    friend class SkCanonicalizePaint;
     friend class SkCanvas;
     friend class SkDraw;
     friend class SkPDFDevice;
-    friend class GrAtlasTextBlob;
-    friend class GrAtlasTextContext;
-    friend class GrStencilAndCoverTextContext;
-    friend class GrPathRendering;
-    friend class GrTextUtils;
-    friend class GrGLPathRendering;
-    friend class SkScalerContext;
+    friend class SkScalerContext;  // for computeLuminanceColor()
     friend class SkTextBaseIter;
-    friend class SkCanonicalizePaint;
 };
 
 #endif