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

Side by Side Diff: xfa/fde/css/fde_cssstyleselector.cpp

Issue 1821043003: Remove FX_WORD in favor of uint16_t. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Use stdint.h directly, bitfield minefield. Created 4 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
« no previous file with comments | « xfa/fde/css/fde_cssstyleselector.h ('k') | xfa/fde/css/fde_cssstylesheet.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 // Copyright 2014 PDFium Authors. All rights reserved. 1 // Copyright 2014 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 6
7 #include "xfa/fde/css/fde_cssstyleselector.h" 7 #include "xfa/fde/css/fde_cssstyleselector.h"
8 8
9 #include <algorithm> 9 #include <algorithm>
10 10
(...skipping 1505 matching lines...) Expand 10 before | Expand all | Expand 10 after
1516 case FDE_CSSPROPERTYVALUE_Center: 1516 case FDE_CSSPROPERTYVALUE_Center:
1517 return FDE_CSSTEXTALIGN_Center; 1517 return FDE_CSSTEXTALIGN_Center;
1518 case FDE_CSSPROPERTYVALUE_Right: 1518 case FDE_CSSPROPERTYVALUE_Right:
1519 return FDE_CSSTEXTALIGN_Right; 1519 return FDE_CSSTEXTALIGN_Right;
1520 case FDE_CSSPROPERTYVALUE_Justify: 1520 case FDE_CSSPROPERTYVALUE_Justify:
1521 return FDE_CSSTEXTALIGN_Justify; 1521 return FDE_CSSTEXTALIGN_Justify;
1522 default: 1522 default:
1523 return FDE_CSSTEXTALIGN_Left; 1523 return FDE_CSSTEXTALIGN_Left;
1524 } 1524 }
1525 } 1525 }
1526 FX_WORD CFDE_CSSStyleSelector::ToFontWeight(FDE_CSSPROPERTYVALUE eValue) { 1526 uint16_t CFDE_CSSStyleSelector::ToFontWeight(FDE_CSSPROPERTYVALUE eValue) {
1527 switch (eValue) { 1527 switch (eValue) {
1528 case FDE_CSSPROPERTYVALUE_Normal: 1528 case FDE_CSSPROPERTYVALUE_Normal:
1529 return 400; 1529 return 400;
1530 case FDE_CSSPROPERTYVALUE_Bold: 1530 case FDE_CSSPROPERTYVALUE_Bold:
1531 return 700; 1531 return 700;
1532 case FDE_CSSPROPERTYVALUE_Bolder: 1532 case FDE_CSSPROPERTYVALUE_Bolder:
1533 return 900; 1533 return 900;
1534 case FDE_CSSPROPERTYVALUE_Lighter: 1534 case FDE_CSSPROPERTYVALUE_Lighter:
1535 return 200; 1535 return 200;
1536 default: 1536 default:
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after
1785 return FDE_CSSTEXTTRANSFORM_LowerCase; 1785 return FDE_CSSTEXTTRANSFORM_LowerCase;
1786 default: 1786 default:
1787 return FDE_CSSTEXTTRANSFORM_None; 1787 return FDE_CSSTEXTTRANSFORM_None;
1788 } 1788 }
1789 } 1789 }
1790 FDE_CSSFONTVARIANT CFDE_CSSStyleSelector::ToFontVariant( 1790 FDE_CSSFONTVARIANT CFDE_CSSStyleSelector::ToFontVariant(
1791 FDE_CSSPROPERTYVALUE eValue) { 1791 FDE_CSSPROPERTYVALUE eValue) {
1792 return eValue == FDE_CSSPROPERTYVALUE_SmallCaps ? FDE_CSSFONTVARIANT_SmallCaps 1792 return eValue == FDE_CSSPROPERTYVALUE_SmallCaps ? FDE_CSSFONTVARIANT_SmallCaps
1793 : FDE_CSSFONTVARIANT_Normal; 1793 : FDE_CSSFONTVARIANT_Normal;
1794 } 1794 }
OLDNEW
« no previous file with comments | « xfa/fde/css/fde_cssstyleselector.h ('k') | xfa/fde/css/fde_cssstylesheet.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698