OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2014 Google Inc. | 2 * Copyright 2014 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #ifndef SkRemotableFontMgr_DEFINED | 8 #ifndef SkRemotableFontMgr_DEFINED |
9 #define SkRemotableFontMgr_DEFINED | 9 #define SkRemotableFontMgr_DEFINED |
10 | 10 |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
54 }; | 54 }; |
55 | 55 |
56 class SK_API SkRemotableFontMgr : public SkRefCnt { | 56 class SK_API SkRemotableFontMgr : public SkRefCnt { |
57 public: | 57 public: |
58 /** | 58 /** |
59 * Returns the names of the known fonts on the system. | 59 * Returns the names of the known fonts on the system. |
60 * Will not return NULL, will return an empty table if no families exist. | 60 * Will not return NULL, will return an empty table if no families exist. |
61 * | 61 * |
62 * The indexes may be used with getIndex(int) and | 62 * The indexes may be used with getIndex(int) and |
63 * matchIndexStyle(int, SkFontStyle). | 63 * matchIndexStyle(int, SkFontStyle). |
64 * | |
65 * The caller must unref() the returned object. | |
66 */ | 64 */ |
67 virtual SkDataTable* getFamilyNames() const = 0; | 65 virtual sk_sp<SkDataTable> getFamilyNames() const = 0; |
68 | 66 |
69 /** | 67 /** |
70 * Returns all of the fonts with the given familyIndex. | 68 * Returns all of the fonts with the given familyIndex. |
71 * Returns NULL if the index is out of bounds. | 69 * Returns NULL if the index is out of bounds. |
72 * Returns empty if there are no fonts at the given index. | 70 * Returns empty if there are no fonts at the given index. |
73 * | 71 * |
74 * The caller must unref() the returned object. | 72 * The caller must unref() the returned object. |
75 */ | 73 */ |
76 virtual SkRemotableFontIdentitySet* getIndex(int familyIndex) const = 0; | 74 virtual SkRemotableFontIdentitySet* getIndex(int familyIndex) const = 0; |
77 | 75 |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
141 * | 139 * |
142 * The caller must unref() the returned object. | 140 * The caller must unref() the returned object. |
143 */ | 141 */ |
144 virtual SkStreamAsset* getData(int dataId) const = 0; | 142 virtual SkStreamAsset* getData(int dataId) const = 0; |
145 | 143 |
146 private: | 144 private: |
147 typedef SkRefCnt INHERITED; | 145 typedef SkRefCnt INHERITED; |
148 }; | 146 }; |
149 | 147 |
150 #endif | 148 #endif |
OLD | NEW |