SkOTTable_OS_2_V2.h 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538
  1. /*
  2. * Copyright 2012 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. #ifndef SkOTTable_OS_2_V2_DEFINED
  8. #define SkOTTable_OS_2_V2_DEFINED
  9. #include "src/core/SkEndian.h"
  10. #include "src/sfnt/SkIBMFamilyClass.h"
  11. #include "src/sfnt/SkOTTableTypes.h"
  12. #include "src/sfnt/SkPanose.h"
  13. #pragma pack(push, 1)
  14. struct SkOTTableOS2_V2 {
  15. SK_OT_USHORT version;
  16. static const SK_OT_USHORT VERSION = SkTEndian_SwapBE16(2);
  17. SK_OT_SHORT xAvgCharWidth;
  18. struct WeightClass {
  19. enum Value : SK_OT_USHORT {
  20. Thin = SkTEndian_SwapBE16(100),
  21. ExtraLight = SkTEndian_SwapBE16(200),
  22. Light = SkTEndian_SwapBE16(300),
  23. Normal = SkTEndian_SwapBE16(400),
  24. Medium = SkTEndian_SwapBE16(500),
  25. SemiBold = SkTEndian_SwapBE16(600),
  26. Bold = SkTEndian_SwapBE16(700),
  27. ExtraBold = SkTEndian_SwapBE16(800),
  28. Black = SkTEndian_SwapBE16(900),
  29. };
  30. SK_OT_USHORT value;
  31. } usWeightClass;
  32. struct WidthClass {
  33. enum Value : SK_OT_USHORT {
  34. UltraCondensed = SkTEndian_SwapBE16(1),
  35. ExtraCondensed = SkTEndian_SwapBE16(2),
  36. Condensed = SkTEndian_SwapBE16(3),
  37. SemiCondensed = SkTEndian_SwapBE16(4),
  38. Medium = SkTEndian_SwapBE16(5),
  39. SemiExpanded = SkTEndian_SwapBE16(6),
  40. Expanded = SkTEndian_SwapBE16(7),
  41. ExtraExpanded = SkTEndian_SwapBE16(8),
  42. UltraExpanded = SkTEndian_SwapBE16(9),
  43. } value;
  44. } usWidthClass;
  45. union Type {
  46. struct Field {
  47. //8-15
  48. SK_OT_BYTE_BITFIELD(
  49. NoSubsetting,
  50. Bitmap,
  51. Reserved10,
  52. Reserved11,
  53. Reserved12,
  54. Reserved13,
  55. Reserved14,
  56. Reserved15)
  57. //0-7
  58. SK_OT_BYTE_BITFIELD(
  59. Reserved00,
  60. Restricted,
  61. PreviewPrint,
  62. Editable,
  63. Reserved04,
  64. Reserved05,
  65. Reserved06,
  66. Reserved07)
  67. } field;
  68. struct Raw {
  69. static const SK_OT_USHORT Installable = 0;
  70. static const SK_OT_USHORT RestrictedMask = SkOTSetUSHORTBit<1>::value;
  71. static const SK_OT_USHORT PreviewPrintMask = SkOTSetUSHORTBit<2>::value;
  72. static const SK_OT_USHORT EditableMask = SkOTSetUSHORTBit<3>::value;
  73. static const SK_OT_USHORT NoSubsettingMask = SkOTSetUSHORTBit<8>::value;
  74. static const SK_OT_USHORT BitmapMask = SkOTSetUSHORTBit<9>::value;
  75. SK_OT_USHORT value;
  76. } raw;
  77. } fsType;
  78. SK_OT_SHORT ySubscriptXSize;
  79. SK_OT_SHORT ySubscriptYSize;
  80. SK_OT_SHORT ySubscriptXOffset;
  81. SK_OT_SHORT ySubscriptYOffset;
  82. SK_OT_SHORT ySuperscriptXSize;
  83. SK_OT_SHORT ySuperscriptYSize;
  84. SK_OT_SHORT ySuperscriptXOffset;
  85. SK_OT_SHORT ySuperscriptYOffset;
  86. SK_OT_SHORT yStrikeoutSize;
  87. SK_OT_SHORT yStrikeoutPosition;
  88. SkIBMFamilyClass sFamilyClass;
  89. SkPanose panose;
  90. union UnicodeRange {
  91. struct Field {
  92. //l0 24-31
  93. SK_OT_BYTE_BITFIELD(
  94. Thai,
  95. Lao,
  96. Georgian,
  97. Reserved027,
  98. HangulJamo,
  99. LatinExtendedAdditional,
  100. GreekExtended,
  101. GeneralPunctuation)
  102. //l0 16-23
  103. SK_OT_BYTE_BITFIELD(
  104. Bengali,
  105. Gurmukhi,
  106. Gujarati,
  107. Oriya,
  108. Tamil,
  109. Telugu,
  110. Kannada,
  111. Malayalam)
  112. //l0 8-15
  113. SK_OT_BYTE_BITFIELD(
  114. Reserved008,
  115. Cyrillic,
  116. Armenian,
  117. Hebrew,
  118. Reserved012,
  119. Arabic,
  120. Reserved014,
  121. Devanagari)
  122. //l0 0-7
  123. SK_OT_BYTE_BITFIELD(
  124. BasicLatin,
  125. Latin1Supplement,
  126. LatinExtendedA,
  127. LatinExtendedB,
  128. IPAExtensions,
  129. SpacingModifierLetters,
  130. CombiningDiacriticalMarks,
  131. Greek)
  132. //l1 24-31
  133. SK_OT_BYTE_BITFIELD(
  134. Hangul,
  135. Surrogates,
  136. Reserved058,
  137. CJKUnifiedIdeographs,
  138. PrivateUseArea,
  139. CJKCompatibilityIdeographs,
  140. AlphabeticPresentationForms,
  141. ArabicPresentationFormsA)
  142. //l1 16-23
  143. SK_OT_BYTE_BITFIELD(
  144. CJKSymbolsAndPunctuation,
  145. Hiragana,
  146. Katakana,
  147. Bopomofo,
  148. HangulCompatibilityJamo,
  149. CJKMiscellaneous,
  150. EnclosedCJKLettersAndMonths,
  151. CJKCompatibility)
  152. //l1 8-15
  153. SK_OT_BYTE_BITFIELD(
  154. ControlPictures,
  155. OpticalCharacterRecognition,
  156. EnclosedAlphanumerics,
  157. BoxDrawing,
  158. BlockElements,
  159. GeometricShapes,
  160. MiscellaneousSymbols,
  161. Dingbats)
  162. //l1 0-7
  163. SK_OT_BYTE_BITFIELD(
  164. SuperscriptsAndSubscripts,
  165. CurrencySymbols,
  166. CombiningDiacriticalMarksForSymbols,
  167. LetterlikeSymbols,
  168. NumberForms,
  169. Arrows,
  170. MathematicalOperators,
  171. MiscellaneousTechnical)
  172. //l2 24-31
  173. SK_OT_BYTE_BITFIELD(
  174. Reserved088,
  175. Reserved089,
  176. Reserved090,
  177. Reserved091,
  178. Reserved092,
  179. Reserved093,
  180. Reserved094,
  181. Reserved095)
  182. //l2 16-23
  183. SK_OT_BYTE_BITFIELD(
  184. Khmer,
  185. Mongolian,
  186. Braille,
  187. Yi,
  188. Reserved084,
  189. Reserved085,
  190. Reserved086,
  191. Reserved087)
  192. //l2 8-15
  193. SK_OT_BYTE_BITFIELD(
  194. Thaana,
  195. Sinhala,
  196. Myanmar,
  197. Ethiopic,
  198. Cherokee,
  199. UnifiedCanadianSyllabics,
  200. Ogham,
  201. Runic)
  202. //l2 0-7
  203. SK_OT_BYTE_BITFIELD(
  204. CombiningHalfMarks,
  205. CJKCompatibilityForms,
  206. SmallFormVariants,
  207. ArabicPresentationFormsB,
  208. HalfwidthAndFullwidthForms,
  209. Specials,
  210. Tibetan,
  211. Syriac)
  212. //l3 24-31
  213. SK_OT_BYTE_BITFIELD(
  214. Reserved120,
  215. Reserved121,
  216. Reserved122,
  217. Reserved123,
  218. Reserved124,
  219. Reserved125,
  220. Reserved126,
  221. Reserved127)
  222. //l3 16-23
  223. SK_OT_BYTE_BITFIELD(
  224. Reserved112,
  225. Reserved113,
  226. Reserved114,
  227. Reserved115,
  228. Reserved116,
  229. Reserved117,
  230. Reserved118,
  231. Reserved119)
  232. //l3 8-15
  233. SK_OT_BYTE_BITFIELD(
  234. Reserved104,
  235. Reserved105,
  236. Reserved106,
  237. Reserved107,
  238. Reserved108,
  239. Reserved109,
  240. Reserved110,
  241. Reserved111)
  242. //l3 0-7
  243. SK_OT_BYTE_BITFIELD(
  244. Reserved096,
  245. Reserved097,
  246. Reserved098,
  247. Reserved099,
  248. Reserved100,
  249. Reserved101,
  250. Reserved102,
  251. Reserved103)
  252. } field;
  253. struct Raw {
  254. struct l0 {
  255. static const SK_OT_ULONG BasicLatinMask = SkOTSetULONGBit<0>::value;
  256. static const SK_OT_ULONG Latin1SupplementMask = SkOTSetULONGBit<1>::value;
  257. static const SK_OT_ULONG LatinExtendedAMask = SkOTSetULONGBit<2>::value;
  258. static const SK_OT_ULONG LatinExtendedBMask = SkOTSetULONGBit<3>::value;
  259. static const SK_OT_ULONG IPAExtensionsMask = SkOTSetULONGBit<4>::value;
  260. static const SK_OT_ULONG SpacingModifierLettersMask = SkOTSetULONGBit<5>::value;
  261. static const SK_OT_ULONG CombiningDiacriticalMarksMask = SkOTSetULONGBit<6>::value;
  262. static const SK_OT_ULONG GreekMask = SkOTSetULONGBit<7>::value;
  263. //Reserved
  264. static const SK_OT_ULONG CyrillicMask = SkOTSetULONGBit<9>::value;
  265. static const SK_OT_ULONG ArmenianMask = SkOTSetULONGBit<10>::value;
  266. static const SK_OT_ULONG HebrewMask = SkOTSetULONGBit<11>::value;
  267. //Reserved
  268. static const SK_OT_ULONG ArabicMask = SkOTSetULONGBit<13>::value;
  269. //Reserved
  270. static const SK_OT_ULONG DevanagariMask = SkOTSetULONGBit<15>::value;
  271. static const SK_OT_ULONG BengaliMask = SkOTSetULONGBit<16>::value;
  272. static const SK_OT_ULONG GurmukhiMask = SkOTSetULONGBit<17>::value;
  273. static const SK_OT_ULONG GujaratiMask = SkOTSetULONGBit<18>::value;
  274. static const SK_OT_ULONG OriyaMask = SkOTSetULONGBit<19>::value;
  275. static const SK_OT_ULONG TamilMask = SkOTSetULONGBit<20>::value;
  276. static const SK_OT_ULONG TeluguMask = SkOTSetULONGBit<21>::value;
  277. static const SK_OT_ULONG KannadaMask = SkOTSetULONGBit<22>::value;
  278. static const SK_OT_ULONG MalayalamMask = SkOTSetULONGBit<23>::value;
  279. static const SK_OT_ULONG ThaiMask = SkOTSetULONGBit<24>::value;
  280. static const SK_OT_ULONG LaoMask = SkOTSetULONGBit<25>::value;
  281. static const SK_OT_ULONG GeorgianMask = SkOTSetULONGBit<26>::value;
  282. //Reserved
  283. static const SK_OT_ULONG HangulJamoMask = SkOTSetULONGBit<28>::value;
  284. static const SK_OT_ULONG LatinExtendedAdditionalMask = SkOTSetULONGBit<29>::value;
  285. static const SK_OT_ULONG GreekExtendedMask = SkOTSetULONGBit<30>::value;
  286. static const SK_OT_ULONG GeneralPunctuationMask = SkOTSetULONGBit<31>::value;
  287. };
  288. struct l1 {
  289. static const SK_OT_ULONG SuperscriptsAndSubscriptsMask = SkOTSetULONGBit<32 - 32>::value;
  290. static const SK_OT_ULONG CurrencySymbolsMask = SkOTSetULONGBit<33 - 32>::value;
  291. static const SK_OT_ULONG CombiningDiacriticalMarksForSymbolsMask = SkOTSetULONGBit<34 - 32>::value;
  292. static const SK_OT_ULONG LetterlikeSymbolsMask = SkOTSetULONGBit<35 - 32>::value;
  293. static const SK_OT_ULONG NumberFormsMask = SkOTSetULONGBit<36 - 32>::value;
  294. static const SK_OT_ULONG ArrowsMask = SkOTSetULONGBit<37 - 32>::value;
  295. static const SK_OT_ULONG MathematicalOperatorsMask = SkOTSetULONGBit<38 - 32>::value;
  296. static const SK_OT_ULONG MiscellaneousTechnicalMask = SkOTSetULONGBit<39 - 32>::value;
  297. static const SK_OT_ULONG ControlPicturesMask = SkOTSetULONGBit<40 - 32>::value;
  298. static const SK_OT_ULONG OpticalCharacterRecognitionMask = SkOTSetULONGBit<41 - 32>::value;
  299. static const SK_OT_ULONG EnclosedAlphanumericsMask = SkOTSetULONGBit<42 - 32>::value;
  300. static const SK_OT_ULONG BoxDrawingMask = SkOTSetULONGBit<43 - 32>::value;
  301. static const SK_OT_ULONG BlockElementsMask = SkOTSetULONGBit<44 - 32>::value;
  302. static const SK_OT_ULONG GeometricShapesMask = SkOTSetULONGBit<45 - 32>::value;
  303. static const SK_OT_ULONG MiscellaneousSymbolsMask = SkOTSetULONGBit<46 - 32>::value;
  304. static const SK_OT_ULONG DingbatsMask = SkOTSetULONGBit<47 - 32>::value;
  305. static const SK_OT_ULONG CJKSymbolsAndPunctuationMask = SkOTSetULONGBit<48 - 32>::value;
  306. static const SK_OT_ULONG HiraganaMask = SkOTSetULONGBit<49 - 32>::value;
  307. static const SK_OT_ULONG KatakanaMask = SkOTSetULONGBit<50 - 32>::value;
  308. static const SK_OT_ULONG BopomofoMask = SkOTSetULONGBit<51 - 32>::value;
  309. static const SK_OT_ULONG HangulCompatibilityJamoMask = SkOTSetULONGBit<52 - 32>::value;
  310. static const SK_OT_ULONG CJKMiscellaneousMask = SkOTSetULONGBit<53 - 32>::value;
  311. static const SK_OT_ULONG EnclosedCJKLettersAndMonthsMask = SkOTSetULONGBit<54 - 32>::value;
  312. static const SK_OT_ULONG CJKCompatibilityMask = SkOTSetULONGBit<55 - 32>::value;
  313. static const SK_OT_ULONG HangulMask = SkOTSetULONGBit<56 - 32>::value;
  314. static const SK_OT_ULONG SurrogatesMask = SkOTSetULONGBit<57 - 32>::value;
  315. //Reserved
  316. static const SK_OT_ULONG CJKUnifiedIdeographsMask = SkOTSetULONGBit<59 - 32>::value;
  317. static const SK_OT_ULONG PrivateUseAreaMask = SkOTSetULONGBit<60 - 32>::value;
  318. static const SK_OT_ULONG CJKCompatibilityIdeographsMask = SkOTSetULONGBit<61 - 32>::value;
  319. static const SK_OT_ULONG AlphabeticPresentationFormsMask = SkOTSetULONGBit<62 - 32>::value;
  320. static const SK_OT_ULONG ArabicPresentationFormsAMask = SkOTSetULONGBit<63 - 32>::value;
  321. };
  322. struct l2 {
  323. static const SK_OT_ULONG CombiningHalfMarksMask = SkOTSetULONGBit<64 - 64>::value;
  324. static const SK_OT_ULONG CJKCompatibilityFormsMask = SkOTSetULONGBit<65 - 64>::value;
  325. static const SK_OT_ULONG SmallFormVariantsMask = SkOTSetULONGBit<66 - 64>::value;
  326. static const SK_OT_ULONG ArabicPresentationFormsBMask = SkOTSetULONGBit<67 - 64>::value;
  327. static const SK_OT_ULONG HalfwidthAndFullwidthFormsMask = SkOTSetULONGBit<68 - 64>::value;
  328. static const SK_OT_ULONG SpecialsMask = SkOTSetULONGBit<69 - 64>::value;
  329. static const SK_OT_ULONG TibetanMask = SkOTSetULONGBit<70 - 64>::value;
  330. static const SK_OT_ULONG SyriacMask = SkOTSetULONGBit<71 - 64>::value;
  331. static const SK_OT_ULONG ThaanaMask = SkOTSetULONGBit<72 - 64>::value;
  332. static const SK_OT_ULONG SinhalaMask = SkOTSetULONGBit<73 - 64>::value;
  333. static const SK_OT_ULONG MyanmarMask = SkOTSetULONGBit<74 - 64>::value;
  334. static const SK_OT_ULONG EthiopicMask = SkOTSetULONGBit<75 - 64>::value;
  335. static const SK_OT_ULONG CherokeeMask = SkOTSetULONGBit<76 - 64>::value;
  336. static const SK_OT_ULONG UnifiedCanadianSyllabicsMask = SkOTSetULONGBit<77 - 64>::value;
  337. static const SK_OT_ULONG OghamMask = SkOTSetULONGBit<78 - 64>::value;
  338. static const SK_OT_ULONG RunicMask = SkOTSetULONGBit<79 - 64>::value;
  339. static const SK_OT_ULONG KhmerMask = SkOTSetULONGBit<80 - 64>::value;
  340. static const SK_OT_ULONG MongolianMask = SkOTSetULONGBit<81 - 64>::value;
  341. static const SK_OT_ULONG BrailleMask = SkOTSetULONGBit<82 - 64>::value;
  342. static const SK_OT_ULONG YiMask = SkOTSetULONGBit<83 - 64>::value;
  343. };
  344. SK_OT_ULONG value[4];
  345. } raw;
  346. } ulUnicodeRange;
  347. SK_OT_CHAR achVendID[4];
  348. union Selection {
  349. struct Field {
  350. //8-15
  351. SK_OT_BYTE_BITFIELD(
  352. Reserved08,
  353. Reserved09,
  354. Reserved10,
  355. Reserved11,
  356. Reserved12,
  357. Reserved13,
  358. Reserved14,
  359. Reserved15)
  360. //0-7
  361. SK_OT_BYTE_BITFIELD(
  362. Italic,
  363. Underscore,
  364. Negative,
  365. Outlined,
  366. Strikeout,
  367. Bold,
  368. Regular,
  369. Reserved07)
  370. } field;
  371. struct Raw {
  372. static const SK_OT_USHORT ItalicMask = SkOTSetUSHORTBit<0>::value;
  373. static const SK_OT_USHORT UnderscoreMask = SkOTSetUSHORTBit<1>::value;
  374. static const SK_OT_USHORT NegativeMask = SkOTSetUSHORTBit<2>::value;
  375. static const SK_OT_USHORT OutlinedMask = SkOTSetUSHORTBit<3>::value;
  376. static const SK_OT_USHORT StrikeoutMask = SkOTSetUSHORTBit<4>::value;
  377. static const SK_OT_USHORT BoldMask = SkOTSetUSHORTBit<5>::value;
  378. static const SK_OT_USHORT RegularMask = SkOTSetUSHORTBit<6>::value;
  379. SK_OT_USHORT value;
  380. } raw;
  381. } fsSelection;
  382. SK_OT_USHORT usFirstCharIndex;
  383. SK_OT_USHORT usLastCharIndex;
  384. //version0
  385. SK_OT_SHORT sTypoAscender;
  386. SK_OT_SHORT sTypoDescender;
  387. SK_OT_SHORT sTypoLineGap;
  388. SK_OT_USHORT usWinAscent;
  389. SK_OT_USHORT usWinDescent;
  390. //version1
  391. union CodePageRange {
  392. struct Field {
  393. //l0 24-31
  394. SK_OT_BYTE_BITFIELD(
  395. Reserved24,
  396. Reserved25,
  397. Reserved26,
  398. Reserved27,
  399. Reserved28,
  400. MacintoshCharacterSet,
  401. OEMCharacterSet,
  402. SymbolCharacterSet)
  403. //l0 16-23
  404. SK_OT_BYTE_BITFIELD(
  405. Thai_874,
  406. JISJapan_932,
  407. ChineseSimplified_936,
  408. KoreanWansung_949,
  409. ChineseTraditional_950,
  410. KoreanJohab_1361,
  411. Reserved22,
  412. Reserved23)
  413. //l0 8-15
  414. SK_OT_BYTE_BITFIELD(
  415. Vietnamese,
  416. Reserved09,
  417. Reserved10,
  418. Reserved11,
  419. Reserved12,
  420. Reserved13,
  421. Reserved14,
  422. Reserved15)
  423. //l0 0-7
  424. SK_OT_BYTE_BITFIELD(
  425. Latin1_1252,
  426. Latin2EasternEurope_1250,
  427. Cyrillic_1251,
  428. Greek_1253,
  429. Turkish_1254,
  430. Hebrew_1255,
  431. Arabic_1256,
  432. WindowsBaltic_1257)
  433. //l1 24-31
  434. SK_OT_BYTE_BITFIELD(
  435. IBMTurkish_857,
  436. IBMCyrillic_855,
  437. Latin2_852,
  438. MSDOSBaltic_775,
  439. Greek_737,
  440. Arabic_708,
  441. WELatin1_850,
  442. US_437)
  443. //l1 16-23
  444. SK_OT_BYTE_BITFIELD(
  445. IBMGreek_869,
  446. MSDOSRussian_866,
  447. MSDOSNordic_865,
  448. Arabic_864,
  449. MSDOSCanadianFrench_863,
  450. Hebrew_862,
  451. MSDOSIcelandic_861,
  452. MSDOSPortuguese_860)
  453. //l1 8-15
  454. SK_OT_BYTE_BITFIELD(
  455. Reserved40,
  456. Reserved41,
  457. Reserved42,
  458. Reserved43,
  459. Reserved44,
  460. Reserved45,
  461. Reserved46,
  462. Reserved47)
  463. //l1 0-7
  464. SK_OT_BYTE_BITFIELD(
  465. Reserved32,
  466. Reserved33,
  467. Reserved34,
  468. Reserved35,
  469. Reserved36,
  470. Reserved37,
  471. Reserved38,
  472. Reserved39)
  473. } field;
  474. struct Raw {
  475. struct l0 {
  476. static const SK_OT_ULONG Latin1_1252Mask = SkOTSetULONGBit<0>::value;
  477. static const SK_OT_ULONG Latin2EasternEurope_1250Mask = SkOTSetULONGBit<1>::value;
  478. static const SK_OT_ULONG Cyrillic_1251Mask = SkOTSetULONGBit<2>::value;
  479. static const SK_OT_ULONG Greek_1253Mask = SkOTSetULONGBit<3>::value;
  480. static const SK_OT_ULONG Turkish_1254Mask = SkOTSetULONGBit<4>::value;
  481. static const SK_OT_ULONG Hebrew_1255Mask = SkOTSetULONGBit<5>::value;
  482. static const SK_OT_ULONG Arabic_1256Mask = SkOTSetULONGBit<6>::value;
  483. static const SK_OT_ULONG WindowsBaltic_1257Mask = SkOTSetULONGBit<7>::value;
  484. static const SK_OT_ULONG Vietnamese_1258Mask = SkOTSetULONGBit<8>::value;
  485. static const SK_OT_ULONG Thai_874Mask = SkOTSetULONGBit<16>::value;
  486. static const SK_OT_ULONG JISJapan_932Mask = SkOTSetULONGBit<17>::value;
  487. static const SK_OT_ULONG ChineseSimplified_936Mask = SkOTSetULONGBit<18>::value;
  488. static const SK_OT_ULONG KoreanWansung_949Mask = SkOTSetULONGBit<19>::value;
  489. static const SK_OT_ULONG ChineseTraditional_950Mask = SkOTSetULONGBit<20>::value;
  490. static const SK_OT_ULONG KoreanJohab_1361Mask = SkOTSetULONGBit<21>::value;
  491. static const SK_OT_ULONG MacintoshCharacterSetMask = SkOTSetULONGBit<29>::value;
  492. static const SK_OT_ULONG OEMCharacterSetMask = SkOTSetULONGBit<30>::value;
  493. static const SK_OT_ULONG SymbolCharacterSetMask = SkOTSetULONGBit<31>::value;
  494. };
  495. struct l1 {
  496. static const SK_OT_ULONG IBMGreek_869Mask = SkOTSetULONGBit<48 - 32>::value;
  497. static const SK_OT_ULONG MSDOSRussian_866Mask = SkOTSetULONGBit<49 - 32>::value;
  498. static const SK_OT_ULONG MSDOSNordic_865Mask = SkOTSetULONGBit<50 - 32>::value;
  499. static const SK_OT_ULONG Arabic_864Mask = SkOTSetULONGBit<51 - 32>::value;
  500. static const SK_OT_ULONG MSDOSCanadianFrench_863Mask = SkOTSetULONGBit<52 - 32>::value;
  501. static const SK_OT_ULONG Hebrew_862Mask = SkOTSetULONGBit<53 - 32>::value;
  502. static const SK_OT_ULONG MSDOSIcelandic_861Mask = SkOTSetULONGBit<54 - 32>::value;
  503. static const SK_OT_ULONG MSDOSPortuguese_860Mask = SkOTSetULONGBit<55 - 32>::value;
  504. static const SK_OT_ULONG IBMTurkish_857Mask = SkOTSetULONGBit<56 - 32>::value;
  505. static const SK_OT_ULONG IBMCyrillic_855Mask = SkOTSetULONGBit<57 - 32>::value;
  506. static const SK_OT_ULONG Latin2_852Mask = SkOTSetULONGBit<58 - 32>::value;
  507. static const SK_OT_ULONG MSDOSBaltic_775Mask = SkOTSetULONGBit<59 - 32>::value;
  508. static const SK_OT_ULONG Greek_737Mask = SkOTSetULONGBit<60 - 32>::value;
  509. static const SK_OT_ULONG Arabic_708Mask = SkOTSetULONGBit<61 - 32>::value;
  510. static const SK_OT_ULONG WELatin1_850Mask = SkOTSetULONGBit<62 - 32>::value;
  511. static const SK_OT_ULONG US_437Mask = SkOTSetULONGBit<63 - 32>::value;
  512. };
  513. SK_OT_ULONG value[2];
  514. } raw;
  515. } ulCodePageRange;
  516. //version2
  517. SK_OT_SHORT sxHeight;
  518. SK_OT_SHORT sCapHeight;
  519. SK_OT_USHORT usDefaultChar;
  520. SK_OT_USHORT usBreakChar;
  521. SK_OT_USHORT usMaxContext;
  522. };
  523. #pragma pack(pop)
  524. static_assert(sizeof(SkOTTableOS2_V2) == 96, "sizeof_SkOTTableOS2_V2_not_96");
  525. #endif