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

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

Issue 189093020: Fix (1 << 31) to (1u << 31) in SkOTTable_OS_2. (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Pedantic Created 6 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « src/sfnt/SkOTTableTypes.h ('k') | src/sfnt/SkOTTable_OS_2_V1.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_OS_2_V0_DEFINED 8 #ifndef SkOTTable_OS_2_V0_DEFINED
9 #define SkOTTable_OS_2_V0_DEFINED 9 #define SkOTTable_OS_2_V0_DEFINED
10 10
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 Reserved00, 69 Reserved00,
70 Restricted, 70 Restricted,
71 PreviewPrint, 71 PreviewPrint,
72 Editable, 72 Editable,
73 Reserved04, 73 Reserved04,
74 Reserved05, 74 Reserved05,
75 Reserved06, 75 Reserved06,
76 Reserved07) 76 Reserved07)
77 } field; 77 } field;
78 struct Raw { 78 struct Raw {
79 static const SK_OT_USHORT Installable = SkTEndian_SwapBE16(0); 79 static const SK_OT_USHORT Installable = 0;
80 static const SK_OT_USHORT RestrictedMask = SkTEndian_SwapBE16(1 << 1 ); 80 static const SK_OT_USHORT RestrictedMask = SkOTSetUSHORTBit<1>::valu e;
81 static const SK_OT_USHORT PreviewPrintMask = SkTEndian_SwapBE16(1 << 2); 81 static const SK_OT_USHORT PreviewPrintMask = SkOTSetUSHORTBit<2>::va lue;
82 static const SK_OT_USHORT EditableMask = SkTEndian_SwapBE16(1 << 3); 82 static const SK_OT_USHORT EditableMask = SkOTSetUSHORTBit<3>::value;
83 SK_OT_USHORT value; 83 SK_OT_USHORT value;
84 } raw; 84 } raw;
85 } fsType; 85 } fsType;
86 SK_OT_SHORT ySubscriptXSize; 86 SK_OT_SHORT ySubscriptXSize;
87 SK_OT_SHORT ySubscriptYSize; 87 SK_OT_SHORT ySubscriptYSize;
88 SK_OT_SHORT ySubscriptXOffset; 88 SK_OT_SHORT ySubscriptXOffset;
89 SK_OT_SHORT ySubscriptYOffset; 89 SK_OT_SHORT ySubscriptYOffset;
90 SK_OT_SHORT ySuperscriptXSize; 90 SK_OT_SHORT ySuperscriptXSize;
91 SK_OT_SHORT ySuperscriptYSize; 91 SK_OT_SHORT ySuperscriptYSize;
92 SK_OT_SHORT ySuperscriptXOffset; 92 SK_OT_SHORT ySuperscriptXOffset;
(...skipping 21 matching lines...) Expand all
114 Italic, 114 Italic,
115 Underscore, 115 Underscore,
116 Negative, 116 Negative,
117 Outlined, 117 Outlined,
118 Strikeout, 118 Strikeout,
119 Bold, 119 Bold,
120 Regular, 120 Regular,
121 Reserved07) 121 Reserved07)
122 } field; 122 } field;
123 struct Raw { 123 struct Raw {
124 static const SK_OT_USHORT ItalicMask = SkTEndian_SwapBE16(1 << 0); 124 static const SK_OT_USHORT ItalicMask = SkOTSetUSHORTBit<0>::value;
125 static const SK_OT_USHORT UnderscoreMask = SkTEndian_SwapBE16(1 << 1 ); 125 static const SK_OT_USHORT UnderscoreMask = SkOTSetUSHORTBit<1>::valu e;
126 static const SK_OT_USHORT NegativeMask = SkTEndian_SwapBE16(1 << 2); 126 static const SK_OT_USHORT NegativeMask = SkOTSetUSHORTBit<2>::value;
127 static const SK_OT_USHORT OutlinedMask = SkTEndian_SwapBE16(1 << 3); 127 static const SK_OT_USHORT OutlinedMask = SkOTSetUSHORTBit<3>::value;
128 static const SK_OT_USHORT StrikeoutMask = SkTEndian_SwapBE16(1 << 4) ; 128 static const SK_OT_USHORT StrikeoutMask = SkOTSetUSHORTBit<4>::value ;
129 static const SK_OT_USHORT BoldMask = SkTEndian_SwapBE16(1 << 5); 129 static const SK_OT_USHORT BoldMask = SkOTSetUSHORTBit<5>::value;
130 static const SK_OT_USHORT RegularMask = SkTEndian_SwapBE16(1 << 6); 130 static const SK_OT_USHORT RegularMask = SkOTSetUSHORTBit<6>::value;
131 SK_OT_USHORT value; 131 SK_OT_USHORT value;
132 } raw; 132 } raw;
133 } fsSelection; 133 } fsSelection;
134 SK_OT_USHORT usFirstCharIndex; 134 SK_OT_USHORT usFirstCharIndex;
135 SK_OT_USHORT usLastCharIndex; 135 SK_OT_USHORT usLastCharIndex;
136 //version0 136 //version0
137 SK_OT_SHORT sTypoAscender; 137 SK_OT_SHORT sTypoAscender;
138 SK_OT_SHORT sTypoDescender; 138 SK_OT_SHORT sTypoDescender;
139 SK_OT_SHORT sTypoLineGap; 139 SK_OT_SHORT sTypoLineGap;
140 SK_OT_USHORT usWinAscent; 140 SK_OT_USHORT usWinAscent;
141 SK_OT_USHORT usWinDescent; 141 SK_OT_USHORT usWinDescent;
142 }; 142 };
143 143
144 #pragma pack(pop) 144 #pragma pack(pop)
145 145
146 146
147 SK_COMPILE_ASSERT(sizeof(SkOTTableOS2_V0) == 78, sizeof_SkOTTableOS2_V0_not_78); 147 SK_COMPILE_ASSERT(sizeof(SkOTTableOS2_V0) == 78, sizeof_SkOTTableOS2_V0_not_78);
148 148
149 #endif 149 #endif
OLDNEW
« no previous file with comments | « src/sfnt/SkOTTableTypes.h ('k') | src/sfnt/SkOTTable_OS_2_V1.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698