blob: b95c91efbb5c41528fcb6e29b20ca7367b4c4f4b [file] [log] [blame]
bungeman@google.comf8d1aee2012-02-02 19:15:21 +00001/*
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"
bungeman@google.comf8d1aee2012-02-02 19:15:21 +000012
13#pragma pack(push, 1)
14
15struct SkIBMFamilyClass {
bungeman4f81caf2016-08-17 10:59:30 -070016 enum class Class : SK_OT_BYTE {
bungeman8fd23a82016-08-16 12:27:49 -070017 NoClassification = 0,
18 OldstyleSerifs = 1,
19 TransitionalSerifs = 2,
20 ModernSerifs = 3,
21 ClarendonSerifs = 4,
22 SlabSerifs = 5,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +000023 //6 reserved for future use
bungeman8fd23a82016-08-16 12:27:49 -070024 FreeformSerifs = 7,
25 SansSerif = 8,
26 Ornamentals = 9,
27 Scripts = 10,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +000028 //11 reserved for future use
bungeman8fd23a82016-08-16 12:27:49 -070029 Symbolic = 12,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +000030 //13-15 reserved for future use
bungeman8fd23a82016-08-16 12:27:49 -070031 } familyClass;
bungeman@google.comf8d1aee2012-02-02 19:15:21 +000032 union SubClass {
bungeman4f81caf2016-08-17 10:59:30 -070033 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,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +000045 } oldstyleSerifs;
bungeman4f81caf2016-08-17 10:59:30 -070046 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,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +000052 } transitionalSerifs;
bungeman4f81caf2016-08-17 10:59:30 -070053 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,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +000059 } modernSerifs;
bungeman4f81caf2016-08-17 10:59:30 -070060 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,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +000071 } clarendonSerifs;
bungeman4f81caf2016-08-17 10:59:30 -070072 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,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +000081 } slabSerifs;
bungeman4f81caf2016-08-17 10:59:30 -070082 enum class FreeformSerifs : SK_OT_BYTE {
83 NoClassification = 0,
84 Modern = 1,
85 //2-14 reserved for future use
86 Miscellaneous = 15,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +000087 } freeformSerifs;
bungeman4f81caf2016-08-17 10:59:30 -070088 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,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +0000101 } sansSerif;
bungeman4f81caf2016-08-17 10:59:30 -0700102 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,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +0000110 } ornamentals;
bungeman4f81caf2016-08-17 10:59:30 -0700111 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,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +0000123 } scripts;
bungeman4f81caf2016-08-17 10:59:30 -0700124 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,
bungeman@google.comf8d1aee2012-02-02 19:15:21 +0000133 } symbolic;
134 } familySubClass;
135};
136
137#pragma pack(pop)
138
139
bungeman99fe8222015-08-20 07:57:51 -0700140static_assert(sizeof(SkIBMFamilyClass) == 2, "sizeof_SkIBMFamilyClass_not_2");
bungeman@google.comf8d1aee2012-02-02 19:15:21 +0000141
142#endif