diff options
author | Dan Sinclair <dsinclair@chromium.org> | 2017-02-09 09:17:20 -0500 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2017-02-09 15:04:51 +0000 |
commit | 1b08df18300bbc67dabd12fb35ab6ce1732a1024 (patch) | |
tree | 9773931c8d18709860c9fbc1177e290e7713044e /xfa/fxbarcode/oned/BC_OneDimWriter.cpp | |
parent | ac2e04797b258115b2dc768a56377d7e78038f42 (diff) | |
download | pdfium-1b08df18300bbc67dabd12fb35ab6ce1732a1024.tar.xz |
Convert Get methods to return instead of using out params.
This Cl changes several Get methods to return their values instead of using
out parameters.
Change-Id: Ie9a930a5c2d0e809f2d7181ca033d801945c1cf9
Reviewed-on: https://pdfium-review.googlesource.com/2556
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Nicolás Peña <npm@chromium.org>
Diffstat (limited to 'xfa/fxbarcode/oned/BC_OneDimWriter.cpp')
-rw-r--r-- | xfa/fxbarcode/oned/BC_OneDimWriter.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/xfa/fxbarcode/oned/BC_OneDimWriter.cpp b/xfa/fxbarcode/oned/BC_OneDimWriter.cpp index 49b1847d9c..93a53a88a1 100644 --- a/xfa/fxbarcode/oned/BC_OneDimWriter.cpp +++ b/xfa/fxbarcode/oned/BC_OneDimWriter.cpp @@ -223,8 +223,8 @@ void CBC_OneDimWriter::ShowDeviceChars(CFX_RenderDevice* device, affine_matrix.Concat(*matrix); } device->DrawNormalText(str.GetLength(), pCharPos, m_pFont, - (FX_FLOAT)iFontSize, &affine_matrix, m_fontColor, - FXTEXT_CLEARTYPE); + static_cast<FX_FLOAT>(iFontSize), &affine_matrix, + m_fontColor, FXTEXT_CLEARTYPE); } void CBC_OneDimWriter::ShowBitmapChars(CFX_DIBitmap* pOutBitmap, @@ -240,9 +240,11 @@ void CBC_OneDimWriter::ShowBitmapChars(CFX_DIBitmap* pOutBitmap, ge.Create((int)geWidth, iTextHeight, m_colorSpace, nullptr); FX_RECT geRect(0, 0, (int)geWidth, iTextHeight); ge.FillRect(&geRect, m_backgroundColor); - CFX_Matrix affine_matrix(1.0, 0.0, 0.0, -1.0, 0.0, (FX_FLOAT)iFontSize); - ge.DrawNormalText(str.GetLength(), pCharPos, m_pFont, (FX_FLOAT)iFontSize, - &affine_matrix, m_fontColor, FXTEXT_CLEARTYPE); + CFX_Matrix affine_matrix(1.0, 0.0, 0.0, -1.0, 0.0, + static_cast<FX_FLOAT>(iFontSize)); + ge.DrawNormalText(str.GetLength(), pCharPos, m_pFont, + static_cast<FX_FLOAT>(iFontSize), &affine_matrix, + m_fontColor, FXTEXT_CLEARTYPE); CFX_FxgeDevice geBitmap; geBitmap.Attach(pOutBitmap, false, nullptr, false); geBitmap.SetDIBits(ge.GetBitmap(), (int)locX, (int)locY); |