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

Side by Side Diff: src/core/SkFontDescriptor.h

Issue 567013002: Serialize the font index. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Update the Custom FontMgr also. Created 6 years, 3 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright 2012 Google Inc. 2 * Copyright 2012 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 SkFontDescriptor_DEFINED 8 #ifndef SkFontDescriptor_DEFINED
9 #define SkFontDescriptor_DEFINED 9 #define SkFontDescriptor_DEFINED
10 10
(...skipping 10 matching lines...) Expand all
21 21
22 void serialize(SkWStream*); 22 void serialize(SkWStream*);
23 23
24 SkTypeface::Style getStyle() { return fStyle; } 24 SkTypeface::Style getStyle() { return fStyle; }
25 void setStyle(SkTypeface::Style style) { fStyle = style; } 25 void setStyle(SkTypeface::Style style) { fStyle = style; }
26 26
27 const char* getFamilyName() { return fFamilyName.c_str(); } 27 const char* getFamilyName() { return fFamilyName.c_str(); }
28 const char* getFullName() { return fFullName.c_str(); } 28 const char* getFullName() { return fFullName.c_str(); }
29 const char* getPostscriptName() { return fPostscriptName.c_str(); } 29 const char* getPostscriptName() { return fPostscriptName.c_str(); }
30 const char* getFontFileName() { return fFontFileName.c_str(); } 30 const char* getFontFileName() { return fFontFileName.c_str(); }
31 int getFontFileIndex() { return fFontFileIndex; }
31 32
32 void setFamilyName(const char* name) { fFamilyName.set(name); } 33 void setFamilyName(const char* name) { fFamilyName.set(name); }
33 void setFullName(const char* name) { fFullName.set(name); } 34 void setFullName(const char* name) { fFullName.set(name); }
34 void setPostscriptName(const char* name) { fPostscriptName.set(name); } 35 void setPostscriptName(const char* name) { fPostscriptName.set(name); }
35 void setFontFileName(const char* name) { fFontFileName.set(name); } 36 void setFontFileName(const char* name) { fFontFileName.set(name); }
37 void setFontFileIndex(int index) { fFontFileIndex = index; }
36 38
37 private: 39 private:
38 SkString fFamilyName; 40 SkString fFamilyName;
39 SkString fFullName; 41 SkString fFullName;
40 SkString fPostscriptName; 42 SkString fPostscriptName;
41 SkString fFontFileName; 43 SkString fFontFileName;
44 int fFontFileIndex;
42 45
43 SkTypeface::Style fStyle; 46 SkTypeface::Style fStyle;
44 }; 47 };
45 48
46 #endif // SkFontDescriptor_DEFINED 49 #endif // SkFontDescriptor_DEFINED
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698