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

Side by Side Diff: core/fpdfapi/render/fpdf_render_text.cpp

Issue 2409173003: Delete unused flags from CFX_SubstFont (Closed)
Patch Set: Created 4 years, 2 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 | « no previous file | core/fxge/cfx_substfont.h » ('j') | core/fxge/cfx_substfont.h » ('J')
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 "core/fpdfapi/render/render_int.h" 7 #include "core/fpdfapi/render/render_int.h"
8 8
9 #include <vector> 9 #include <vector>
10 10
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 if (pClippingPath) { 50 if (pClippingPath) {
51 bClip = true; 51 bClip = true;
52 } else { 52 } else {
53 switch (text_render_mode) { 53 switch (text_render_mode) {
54 case TextRenderingMode::MODE_FILL: 54 case TextRenderingMode::MODE_FILL:
55 case TextRenderingMode::MODE_FILL_CLIP: 55 case TextRenderingMode::MODE_FILL_CLIP:
56 bFill = true; 56 bFill = true;
57 break; 57 break;
58 case TextRenderingMode::MODE_STROKE: 58 case TextRenderingMode::MODE_STROKE:
59 case TextRenderingMode::MODE_STROKE_CLIP: 59 case TextRenderingMode::MODE_STROKE_CLIP:
60 if (pFont->GetFace() || 60 if (pFont->GetFace())
61 (pFont->GetSubstFont()->m_SubstFlags & FXFONT_SUBST_GLYPHPATH)) {
62 bStroke = true; 61 bStroke = true;
63 } else { 62 else
64 bFill = true; 63 bFill = true;
65 }
66 break; 64 break;
67 case TextRenderingMode::MODE_FILL_STROKE: 65 case TextRenderingMode::MODE_FILL_STROKE:
68 case TextRenderingMode::MODE_FILL_STROKE_CLIP: 66 case TextRenderingMode::MODE_FILL_STROKE_CLIP:
69 bFill = true; 67 bFill = true;
70 if (pFont->GetFace() || 68 if (pFont->GetFace())
71 (pFont->GetSubstFont()->m_SubstFlags & FXFONT_SUBST_GLYPHPATH)) {
72 bStroke = true; 69 bStroke = true;
73 }
74 break; 70 break;
75 case TextRenderingMode::MODE_INVISIBLE: 71 case TextRenderingMode::MODE_INVISIBLE:
76 // Already handled above, but the compiler is not smart enough to 72 // Already handled above, but the compiler is not smart enough to
77 // realize it. Fall through. 73 // realize it. Fall through.
78 ASSERT(false); 74 ASSERT(false);
79 case TextRenderingMode::MODE_CLIP: 75 case TextRenderingMode::MODE_CLIP:
80 return TRUE; 76 return TRUE;
81 } 77 }
82 } 78 }
83 FX_ARGB stroke_argb = 0; 79 FX_ARGB stroke_argb = 0;
(...skipping 559 matching lines...) Expand 10 before | Expand all | Expand 10 after
643 matrix.Concat(font_size, 0, 0, font_size, charpos.m_OriginX, 639 matrix.Concat(font_size, 0, 0, font_size, charpos.m_OriginX,
644 charpos.m_OriginY); 640 charpos.m_OriginY);
645 path.m_Path.Append(pPath, &matrix); 641 path.m_Path.Append(pPath, &matrix);
646 path.m_Matrix = *pTextMatrix; 642 path.m_Matrix = *pTextMatrix;
647 path.m_bStroke = bStroke; 643 path.m_bStroke = bStroke;
648 path.m_FillType = bFill ? FXFILL_WINDING : 0; 644 path.m_FillType = bFill ? FXFILL_WINDING : 0;
649 path.CalcBoundingBox(); 645 path.CalcBoundingBox();
650 ProcessPath(&path, pObj2Device); 646 ProcessPath(&path, pObj2Device);
651 } 647 }
652 } 648 }
OLDNEW
« no previous file with comments | « no previous file | core/fxge/cfx_substfont.h » ('j') | core/fxge/cfx_substfont.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698