OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2011 The Android Open Source Project | 2 * Copyright 2011 The Android Open Source Project |
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 SKFONTCONFIGPARSER_ANDROID_H_ | 8 #ifndef SKFONTCONFIGPARSER_ANDROID_H_ |
9 #define SKFONTCONFIGPARSER_ANDROID_H_ | 9 #define SKFONTCONFIGPARSER_ANDROID_H_ |
10 | 10 |
11 #include "SkTypes.h" | 11 #include "SkTypes.h" |
12 | 12 |
13 #include "SkPaintOptionsAndroid.h" | 13 #include "SkPaintOptionsAndroid.h" |
14 #include "SkString.h" | 14 #include "SkString.h" |
15 #include "SkTDArray.h" | 15 #include "SkTDArray.h" |
16 | 16 |
17 struct FontFileInfo { | 17 struct FontFileInfo { |
| 18 FontFileInfo() : fIndex(0) { } |
| 19 |
18 SkString fFileName; | 20 SkString fFileName; |
| 21 int fIndex; |
19 SkPaintOptionsAndroid fPaintOptions; | 22 SkPaintOptionsAndroid fPaintOptions; |
20 }; | 23 }; |
21 | 24 |
22 /** | 25 /** |
23 * The FontFamily data structure is created during parsing and handed back to | 26 * The FontFamily data structure is created during parsing and handed back to |
24 * Skia to fold into its representation of font families. fNames is the list of | 27 * Skia to fold into its representation of font families. fNames is the list of |
25 * font names that alias to a font family. fontFileArray is the list of informat
ion | 28 * font names that alias to a font family. fontFileArray is the list of informat
ion |
26 * about each file. Order is the priority order for the font. This is | 29 * about each file. Order is the priority order for the font. This is |
27 * used internally to determine the order in which to place fallback fonts as | 30 * used internally to determine the order in which to place fallback fonts as |
28 * they are read from the configuration files. | 31 * they are read from the configuration files. |
(...skipping 21 matching lines...) Expand all Loading... |
50 */ | 53 */ |
51 void GetTestFontFamilies(SkTDArray<FontFamily*> &fontFamilies, | 54 void GetTestFontFamilies(SkTDArray<FontFamily*> &fontFamilies, |
52 const char* testMainConfigFile, | 55 const char* testMainConfigFile, |
53 const char* testFallbackConfigFile); | 56 const char* testFallbackConfigFile); |
54 | 57 |
55 SkString GetLocale(); | 58 SkString GetLocale(); |
56 | 59 |
57 } // SkFontConfigParser namespace | 60 } // SkFontConfigParser namespace |
58 | 61 |
59 #endif /* SKFONTCONFIGPARSER_ANDROID_H_ */ | 62 #endif /* SKFONTCONFIGPARSER_ANDROID_H_ */ |
OLD | NEW |