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

Side by Side Diff: xfa/fxgraphics/cfx_graphics.cpp

Issue 2010813003: Remove default arguments from CFX_FxgeDevice. (Closed) Base URL: https://pdfium.googlesource.com/pdfium@fxgeclean2_textrenderer
Patch Set: rebase Created 4 years, 6 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/fxgraphics/cagg_graphics.cpp ('k') | no next file » | 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/fxgraphics/include/cfx_graphics.h" 7 #include "xfa/fxgraphics/include/cfx_graphics.h"
8 8
9 #include <memory> 9 #include <memory>
10 10
(...skipping 1325 matching lines...) Expand 10 before | Expand all | Expand 10 after
1336 CFX_DIBitmap mask; 1336 CFX_DIBitmap mask;
1337 mask.Create(data.width, data.height, FXDIB_1bppMask); 1337 mask.Create(data.width, data.height, FXDIB_1bppMask);
1338 FXSYS_memcpy(mask.GetBuffer(), data.maskBits, mask.GetPitch() * data.height); 1338 FXSYS_memcpy(mask.GetBuffer(), data.maskBits, mask.GetPitch() * data.height);
1339 CFX_FloatRect rectf = path->GetPathData()->GetBoundingBox(); 1339 CFX_FloatRect rectf = path->GetPathData()->GetBoundingBox();
1340 if (matrix) { 1340 if (matrix) {
1341 rectf.Transform((const CFX_Matrix*)matrix); 1341 rectf.Transform((const CFX_Matrix*)matrix);
1342 } 1342 }
1343 FX_RECT rect(FXSYS_round(rectf.left), FXSYS_round(rectf.top), 1343 FX_RECT rect(FXSYS_round(rectf.left), FXSYS_round(rectf.top),
1344 FXSYS_round(rectf.right), FXSYS_round(rectf.bottom)); 1344 FXSYS_round(rectf.right), FXSYS_round(rectf.bottom));
1345 CFX_FxgeDevice device; 1345 CFX_FxgeDevice device;
1346 device.Attach(&bmp); 1346 device.Attach(&bmp, false, nullptr, false);
1347 device.FillRect(&rect, m_info.fillColor->m_info.pattern->m_backArgb); 1347 device.FillRect(&rect, m_info.fillColor->m_info.pattern->m_backArgb);
1348 for (int32_t j = rect.bottom; j < rect.top; j += mask.GetHeight()) { 1348 for (int32_t j = rect.bottom; j < rect.top; j += mask.GetHeight()) {
1349 for (int32_t i = rect.left; i < rect.right; i += mask.GetWidth()) { 1349 for (int32_t i = rect.left; i < rect.right; i += mask.GetWidth()) {
1350 device.SetBitMask(&mask, i, j, 1350 device.SetBitMask(&mask, i, j,
1351 m_info.fillColor->m_info.pattern->m_foreArgb); 1351 m_info.fillColor->m_info.pattern->m_foreArgb);
1352 } 1352 }
1353 } 1353 }
1354 1354
1355 m_renderDevice->SaveState(); 1355 m_renderDevice->SaveState();
1356 m_renderDevice->SetClip_PathFill(path->GetPathData(), (CFX_Matrix*)matrix, 1356 m_renderDevice->SetClip_PathFill(path->GetPathData(), (CFX_Matrix*)matrix,
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after
1565 CTM = other.CTM; 1565 CTM = other.CTM;
1566 isActOnDash = other.isActOnDash; 1566 isActOnDash = other.isActOnDash;
1567 strokeColor = other.strokeColor; 1567 strokeColor = other.strokeColor;
1568 fillColor = other.fillColor; 1568 fillColor = other.fillColor;
1569 font = other.font; 1569 font = other.font;
1570 fontSize = other.fontSize; 1570 fontSize = other.fontSize;
1571 fontHScale = other.fontHScale; 1571 fontHScale = other.fontHScale;
1572 fontSpacing = other.fontSpacing; 1572 fontSpacing = other.fontSpacing;
1573 return *this; 1573 return *this;
1574 } 1574 }
OLDNEW
« no previous file with comments | « xfa/fxgraphics/cagg_graphics.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698