Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(201)

Side by Side Diff: src/sfnt/SkOTTable_post.h

Issue 2254513002: Remove SkPreprocessorSeq.h and SkTypedEnum.h. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/sfnt/SkOTTable_name.h ('k') | src/sfnt/SkPanose.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2012 Google Inc. 2 * Copyright 2012 Google Inc.
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 SkOTTable_post_DEFINED 8 #ifndef SkOTTable_post_DEFINED
9 #define SkOTTable_post_DEFINED 9 #define SkOTTable_post_DEFINED
10 10
11 #include "SkEndian.h" 11 #include "SkEndian.h"
12 #include "SkOTTableTypes.h" 12 #include "SkOTTableTypes.h"
13 #include "SkTypedEnum.h"
14 13
15 #pragma pack(push, 1) 14 #pragma pack(push, 1)
16 15
17 struct SkOTTablePostScript { 16 struct SkOTTablePostScript {
18 static const SK_OT_CHAR TAG0 = 'p'; 17 static const SK_OT_CHAR TAG0 = 'p';
19 static const SK_OT_CHAR TAG1 = 'o'; 18 static const SK_OT_CHAR TAG1 = 'o';
20 static const SK_OT_CHAR TAG2 = 's'; 19 static const SK_OT_CHAR TAG2 = 's';
21 static const SK_OT_CHAR TAG3 = 't'; 20 static const SK_OT_CHAR TAG3 = 't';
22 static const SK_OT_ULONG TAG = SkOTTableTAG<SkOTTablePostScript>::value; 21 static const SK_OT_ULONG TAG = SkOTTableTAG<SkOTTablePostScript>::value;
23 22
24 struct Format { 23 struct Format {
25 SK_TYPED_ENUM(Value, SK_OT_Fixed, 24 enum Value : SK_OT_Fixed {
26 ((version1, SkTEndian_SwapBE32(0x00010000))) 25 version1 = SkTEndian_SwapBE32(0x00010000),
27 ((version2, SkTEndian_SwapBE32(0x00020000))) 26 version2 = SkTEndian_SwapBE32(0x00020000),
28 ((version2_5, SkTEndian_SwapBE32(0x00025000))) 27 version2_5 = SkTEndian_SwapBE32(0x00025000),
29 ((version3, SkTEndian_SwapBE32(0x00030000))) 28 version3 = SkTEndian_SwapBE32(0x00030000),
30 ((version4, SkTEndian_SwapBE32(0x00040000))) 29 version4 = SkTEndian_SwapBE32(0x00040000),
31 SK_SEQ_END, 30 };
32 SK_SEQ_END)
33 SK_OT_Fixed value; 31 SK_OT_Fixed value;
34 } format; 32 } format;
35 SK_OT_Fixed italicAngle; 33 SK_OT_Fixed italicAngle;
36 SK_OT_FWORD underlinePosition; 34 SK_OT_FWORD underlinePosition;
37 SK_OT_FWORD underlineThickness; 35 SK_OT_FWORD underlineThickness;
38 SK_OT_ULONG isFixedPitch; 36 SK_OT_ULONG isFixedPitch;
39 SK_OT_ULONG minMemType42; 37 SK_OT_ULONG minMemType42;
40 SK_OT_ULONG maxMemType42; 38 SK_OT_ULONG maxMemType42;
41 SK_OT_ULONG minMemType1; 39 SK_OT_ULONG minMemType1;
42 SK_OT_ULONG maxMemType1; 40 SK_OT_ULONG maxMemType1;
43 }; 41 };
44 42
45 #pragma pack(pop) 43 #pragma pack(pop)
46 44
47 45
48 #include <stddef.h> 46 #include <stddef.h>
49 static_assert(offsetof(SkOTTablePostScript, maxMemType1) == 28, "SkOTTablePostSc ript_maxMemType1_not_at_28"); 47 static_assert(offsetof(SkOTTablePostScript, maxMemType1) == 28, "SkOTTablePostSc ript_maxMemType1_not_at_28");
50 static_assert(sizeof(SkOTTablePostScript) == 32, "sizeof_SkOTTablePostScript_not _32"); 48 static_assert(sizeof(SkOTTablePostScript) == 32, "sizeof_SkOTTablePostScript_not _32");
51 49
52 #endif 50 #endif
OLDNEW
« no previous file with comments | « src/sfnt/SkOTTable_name.h ('k') | src/sfnt/SkPanose.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698