caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2015 Google Inc. |
| 3 | * |
| 4 | * Use of this source code is governed by a BSD-style license that can be |
| 5 | * found in the LICENSE file. |
| 6 | */ |
| 7 | |
| 8 | // Auto-generated by create_test_font.cpp |
| 9 | |
| 10 | static SkTestFontData gTestFonts[] = { |
| 11 | { LiberationMonoNormalPoints, LiberationMonoNormalVerbs, LiberationMonoNormalCharCodes, |
| 12 | LiberationMonoNormalCharCodesCount, LiberationMonoNormalWidths, |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 13 | LiberationMonoNormalMetrics, "Toy Liberation Mono", SkFontStyle(400,5,SkFontStyle::kUpright_Slant), nullptr |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 14 | }, |
| 15 | { LiberationMonoBoldPoints, LiberationMonoBoldVerbs, LiberationMonoBoldCharCodes, |
| 16 | LiberationMonoBoldCharCodesCount, LiberationMonoBoldWidths, |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 17 | LiberationMonoBoldMetrics, "Toy Liberation Mono", SkFontStyle(700,5,SkFontStyle::kUpright_Slant), nullptr |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 18 | }, |
| 19 | { LiberationMonoItalicPoints, LiberationMonoItalicVerbs, LiberationMonoItalicCharCodes, |
| 20 | LiberationMonoItalicCharCodesCount, LiberationMonoItalicWidths, |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 21 | LiberationMonoItalicMetrics, "Toy Liberation Mono", SkFontStyle(400,5,SkFontStyle::kItalic_Slant), nullptr |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 22 | }, |
| 23 | { LiberationMonoBoldItalicPoints, LiberationMonoBoldItalicVerbs, LiberationMonoBoldItalicCharCodes, |
| 24 | LiberationMonoBoldItalicCharCodesCount, LiberationMonoBoldItalicWidths, |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 25 | LiberationMonoBoldItalicMetrics, "Toy Liberation Mono", SkFontStyle(700,5,SkFontStyle::kItalic_Slant), nullptr |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 26 | }, |
| 27 | { LiberationSansNormalPoints, LiberationSansNormalVerbs, LiberationSansNormalCharCodes, |
| 28 | LiberationSansNormalCharCodesCount, LiberationSansNormalWidths, |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 29 | LiberationSansNormalMetrics, "Toy Liberation Sans", SkFontStyle(400,5,SkFontStyle::kUpright_Slant), nullptr |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 30 | }, |
| 31 | { LiberationSansBoldPoints, LiberationSansBoldVerbs, LiberationSansBoldCharCodes, |
| 32 | LiberationSansBoldCharCodesCount, LiberationSansBoldWidths, |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 33 | LiberationSansBoldMetrics, "Toy Liberation Sans", SkFontStyle(700,5,SkFontStyle::kUpright_Slant), nullptr |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 34 | }, |
| 35 | { LiberationSansItalicPoints, LiberationSansItalicVerbs, LiberationSansItalicCharCodes, |
| 36 | LiberationSansItalicCharCodesCount, LiberationSansItalicWidths, |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 37 | LiberationSansItalicMetrics, "Toy Liberation Sans", SkFontStyle(400,5,SkFontStyle::kItalic_Slant), nullptr |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 38 | }, |
| 39 | { LiberationSansBoldItalicPoints, LiberationSansBoldItalicVerbs, LiberationSansBoldItalicCharCodes, |
| 40 | LiberationSansBoldItalicCharCodesCount, LiberationSansBoldItalicWidths, |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 41 | LiberationSansBoldItalicMetrics, "Toy Liberation Sans", SkFontStyle(700,5,SkFontStyle::kItalic_Slant), nullptr |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 42 | }, |
| 43 | { LiberationSerifNormalPoints, LiberationSerifNormalVerbs, LiberationSerifNormalCharCodes, |
| 44 | LiberationSerifNormalCharCodesCount, LiberationSerifNormalWidths, |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 45 | LiberationSerifNormalMetrics, "Toy Liberation Serif", SkFontStyle(400,5,SkFontStyle::kUpright_Slant), nullptr |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 46 | }, |
| 47 | { LiberationSerifBoldPoints, LiberationSerifBoldVerbs, LiberationSerifBoldCharCodes, |
| 48 | LiberationSerifBoldCharCodesCount, LiberationSerifBoldWidths, |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 49 | LiberationSerifBoldMetrics, "Toy Liberation Serif", SkFontStyle(700,5,SkFontStyle::kUpright_Slant), nullptr |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 50 | }, |
| 51 | { LiberationSerifItalicPoints, LiberationSerifItalicVerbs, LiberationSerifItalicCharCodes, |
| 52 | LiberationSerifItalicCharCodesCount, LiberationSerifItalicWidths, |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 53 | LiberationSerifItalicMetrics, "Toy Liberation Serif", SkFontStyle(400,5,SkFontStyle::kItalic_Slant), nullptr |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 54 | }, |
| 55 | { LiberationSerifBoldItalicPoints, LiberationSerifBoldItalicVerbs, LiberationSerifBoldItalicCharCodes, |
| 56 | LiberationSerifBoldItalicCharCodesCount, LiberationSerifBoldItalicWidths, |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 57 | LiberationSerifBoldItalicMetrics, "Toy Liberation Serif", SkFontStyle(700,5,SkFontStyle::kItalic_Slant), nullptr |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 58 | }, |
| 59 | }; |
| 60 | |
| 61 | const int gTestFontsCount = (int) SK_ARRAY_COUNT(gTestFonts); |
| 62 | |
| 63 | struct SubFont { |
| 64 | const char* fName; |
mboc | ee6a991 | 2016-05-31 11:42:36 -0700 | [diff] [blame] | 65 | SkFontStyle fStyle; |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 66 | SkTestFontData& fFont; |
| 67 | const char* fFile; |
| 68 | }; |
| 69 | |
| 70 | const SubFont gSubFonts[] = { |
Ben Wagner | 219f362 | 2017-07-17 15:32:25 -0400 | [diff] [blame] | 71 | { "monospace", SkFontStyle(400,5,SkFontStyle::kUpright_Slant), gTestFonts[0], "LiberationMono-Regular.ttf" }, |
| 72 | { "monospace", SkFontStyle(700,5,SkFontStyle::kUpright_Slant), gTestFonts[1], "LiberationMono-Bold.ttf" }, |
| 73 | { "monospace", SkFontStyle(400,5,SkFontStyle::kItalic_Slant), gTestFonts[2], "LiberationMono-Italic.ttf" }, |
| 74 | { "monospace", SkFontStyle(700,5,SkFontStyle::kItalic_Slant), gTestFonts[3], "LiberationMono-BoldItalic.ttf" }, |
| 75 | { "sans-serif", SkFontStyle(400,5,SkFontStyle::kUpright_Slant), gTestFonts[4], "LiberationSans-Regular.ttf" }, |
| 76 | { "sans-serif", SkFontStyle(700,5,SkFontStyle::kUpright_Slant), gTestFonts[5], "LiberationSans-Bold.ttf" }, |
| 77 | { "sans-serif", SkFontStyle(400,5,SkFontStyle::kItalic_Slant), gTestFonts[6], "LiberationSans-Italic.ttf" }, |
| 78 | { "sans-serif", SkFontStyle(700,5,SkFontStyle::kItalic_Slant), gTestFonts[7], "LiberationSans-BoldItalic.ttf" }, |
| 79 | { "serif", SkFontStyle(400,5,SkFontStyle::kUpright_Slant), gTestFonts[8], "LiberationSerif-Regular.ttf" }, |
| 80 | { "serif", SkFontStyle(700,5,SkFontStyle::kUpright_Slant), gTestFonts[9], "LiberationSerif-Bold.ttf" }, |
| 81 | { "serif", SkFontStyle(400,5,SkFontStyle::kItalic_Slant), gTestFonts[10], "LiberationSerif-Italic.ttf" }, |
| 82 | { "serif", SkFontStyle(700,5,SkFontStyle::kItalic_Slant), gTestFonts[11], "LiberationSerif-BoldItalic.ttf" }, |
| 83 | { "Toy Liberation Mono", SkFontStyle(400,5,SkFontStyle::kUpright_Slant), gTestFonts[0], "LiberationMono-Regular.ttf" }, |
| 84 | { "Toy Liberation Mono", SkFontStyle(700,5,SkFontStyle::kUpright_Slant), gTestFonts[1], "LiberationMono-Bold.ttf" }, |
| 85 | { "Toy Liberation Mono", SkFontStyle(400,5,SkFontStyle::kItalic_Slant), gTestFonts[2], "LiberationMono-Italic.ttf" }, |
| 86 | { "Toy Liberation Mono", SkFontStyle(700,5,SkFontStyle::kItalic_Slant), gTestFonts[3], "LiberationMono-BoldItalic.ttf" }, |
| 87 | { "Toy Liberation Sans", SkFontStyle(400,5,SkFontStyle::kUpright_Slant), gTestFonts[4], "LiberationSans-Regular.ttf" }, |
| 88 | { "Toy Liberation Sans", SkFontStyle(700,5,SkFontStyle::kUpright_Slant), gTestFonts[5], "LiberationSans-Bold.ttf" }, |
| 89 | { "Toy Liberation Sans", SkFontStyle(400,5,SkFontStyle::kItalic_Slant), gTestFonts[6], "LiberationSans-Italic.ttf" }, |
| 90 | { "Toy Liberation Sans", SkFontStyle(700,5,SkFontStyle::kItalic_Slant), gTestFonts[7], "LiberationSans-BoldItalic.ttf" }, |
| 91 | { "Toy Liberation Serif", SkFontStyle(400,5,SkFontStyle::kUpright_Slant), gTestFonts[8], "LiberationSerif-Regular.ttf" }, |
| 92 | { "Toy Liberation Serif", SkFontStyle(700,5,SkFontStyle::kUpright_Slant), gTestFonts[9], "LiberationSerif-Bold.ttf" }, |
| 93 | { "Toy Liberation Serif", SkFontStyle(400,5,SkFontStyle::kItalic_Slant), gTestFonts[10], "LiberationSerif-Italic.ttf" }, |
| 94 | { "Toy Liberation Serif", SkFontStyle(700,5,SkFontStyle::kItalic_Slant), gTestFonts[11], "LiberationSerif-BoldItalic.ttf" }, |
caryclark | 83ca628 | 2015-06-10 09:31:09 -0700 | [diff] [blame] | 95 | }; |
| 96 | |
| 97 | const int gSubFontsCount = (int) SK_ARRAY_COUNT(gSubFonts); |
| 98 | |
| 99 | const int gDefaultFontIndex = 4; |