• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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 
8 #ifndef SkIBMFamilyClass_DEFINED
9 #define SkIBMFamilyClass_DEFINED
10 
11 #include "SkOTTableTypes.h"
12 
13 #pragma pack(push, 1)
14 
15 struct SkIBMFamilyClass {
16     enum class Class : SK_OT_BYTE {
17         NoClassification = 0,
18         OldstyleSerifs = 1,
19         TransitionalSerifs = 2,
20         ModernSerifs = 3,
21         ClarendonSerifs = 4,
22         SlabSerifs = 5,
23         //6 reserved for future use
24         FreeformSerifs = 7,
25         SansSerif = 8,
26         Ornamentals = 9,
27         Scripts = 10,
28         //11 reserved for future use
29         Symbolic = 12,
30         //13-15 reserved for future use
31     } familyClass;
32     union SubClass {
33         enum class OldstyleSerifs : SK_OT_BYTE {
34             NoClassification = 0,
35             IBMRoundedLegibility = 1,
36             Garalde = 2,
37             Venetian = 3,
38             ModifiedVenetian = 4,
39             DutchModern = 5,
40             DutchTraditional = 6,
41             Contemporary = 7,
42             Calligraphic = 8,
43             //9-14 reserved for future use
44             Miscellaneous = 15,
45         } oldstyleSerifs;
46         enum class TransitionalSerifs : SK_OT_BYTE {
47             NoClassification = 0,
48             DirectLine = 1,
49             Script = 2,
50             //3-14 reserved for future use
51             Miscellaneous = 15,
52         } transitionalSerifs;
53         enum class ModernSerifs : SK_OT_BYTE {
54             NoClassification = 0,
55             Italian = 1,
56             Script = 2,
57             //3-14 reserved for future use
58             Miscellaneous = 15,
59         } modernSerifs;
60         enum class ClarendonSerifs : SK_OT_BYTE {
61             NoClassification = 0,
62             Clarendon = 1,
63             Modern = 2,
64             Traditional = 3,
65             Newspaper = 4,
66             StubSerif = 5,
67             Monotone = 6,
68             Typewriter = 7,
69             //8-14 reserved for future use
70             Miscellaneous = 15,
71         } clarendonSerifs;
72         enum class SlabSerifs : SK_OT_BYTE {
73             NoClassification = 0,
74             Monotone = 1,
75             Humanist = 2,
76             Geometric = 3,
77             Swiss = 4,
78             Typewriter = 5,
79             //6-14 reserved for future use
80             Miscellaneous = 15,
81         } slabSerifs;
82         enum class FreeformSerifs : SK_OT_BYTE {
83             NoClassification = 0,
84             Modern = 1,
85             //2-14 reserved for future use
86             Miscellaneous = 15,
87         } freeformSerifs;
88         enum class SansSerif : SK_OT_BYTE {
89             NoClassification = 0,
90             IBMNeoGrotesqueGothic = 1,
91             Humanist = 2,
92             LowXRoundGeometric = 3,
93             HighXRoundGeometric = 4,
94             NeoGrotesqueGothic = 5,
95             ModifiedNeoGrotesqueGothic = 6,
96             //7-8 reserved for future use
97             TypewriterGothic = 9,
98             Matrix = 10,
99             //11-14 reserved for future use
100             Miscellaneous = 15,
101         } sansSerif;
102         enum class Ornamentals : SK_OT_BYTE {
103             NoClassification = 0,
104             Engraver = 1,
105             BlackLetter = 2,
106             Decorative = 3,
107             ThreeDimensional = 4,
108             //5-14 reserved for future use
109             Miscellaneous = 15,
110         } ornamentals;
111         enum class Scripts : SK_OT_BYTE {
112             NoClassification = 0,
113             Uncial = 1,
114             Brush_Joined = 2,
115             Formal_Joined = 3,
116             Monotone_Joined = 4,
117             Calligraphic = 5,
118             Brush_Unjoined = 6,
119             Formal_Unjoined = 7,
120             Monotone_Unjoined = 8,
121             //9-14 reserved for future use
122             Miscellaneous = 15,
123         } scripts;
124         enum class Symbolic : SK_OT_BYTE {
125             NoClassification = 0,
126             //1-2 reserved for future use
127             MixedSerif = 3,
128             //4-5 reserved for future use
129             OldstyleSerif = 6,
130             NeoGrotesqueSansSerif = 7,
131             //8-14 reserved for future use
132             Miscellaneous = 15,
133         } symbolic;
134     } familySubClass;
135 };
136 
137 #pragma pack(pop)
138 
139 
140 static_assert(sizeof(SkIBMFamilyClass) == 2, "sizeof_SkIBMFamilyClass_not_2");
141 
142 #endif
143