diff options
Diffstat (limited to 'fpdfsdk')
-rw-r--r-- | fpdfsdk/fpdfformfill.cpp | 8 | ||||
-rw-r--r-- | fpdfsdk/fpdfview.cpp | 7 | ||||
-rw-r--r-- | fpdfsdk/fxedit/fxet_edit.cpp | 4 |
3 files changed, 7 insertions, 12 deletions
diff --git a/fpdfsdk/fpdfformfill.cpp b/fpdfsdk/fpdfformfill.cpp index f2ae621098..24cd64efa1 100644 --- a/fpdfsdk/fpdfformfill.cpp +++ b/fpdfsdk/fpdfformfill.cpp @@ -126,11 +126,9 @@ void FFLCommon(FPDF_FORMHANDLE hHandle, options.m_Flags &= ~RENDER_CLEARTYPE; // Grayscale output - if (flags & FPDF_GRAYSCALE) { - options.m_ColorMode = RENDER_COLOR_GRAY; - options.m_ForeColor = 0; - options.m_BackColor = 0xffffff; - } + if (flags & FPDF_GRAYSCALE) + options.m_ColorMode = CPDF_RenderOptions::kGray; + options.m_bDrawAnnots = flags & FPDF_ANNOT; #ifdef PDF_ENABLE_XFA diff --git a/fpdfsdk/fpdfview.cpp b/fpdfsdk/fpdfview.cpp index 48322a74dc..905d3683a0 100644 --- a/fpdfsdk/fpdfview.cpp +++ b/fpdfsdk/fpdfview.cpp @@ -101,11 +101,8 @@ void RenderPageImpl(CPDF_PageRenderContext* pContext, #endif // PDF_ENABLE_XFA // Grayscale output - if (flags & FPDF_GRAYSCALE) { - pContext->m_pOptions->m_ColorMode = RENDER_COLOR_GRAY; - pContext->m_pOptions->m_ForeColor = 0; - pContext->m_pOptions->m_BackColor = 0xffffff; - } + if (flags & FPDF_GRAYSCALE) + pContext->m_pOptions->m_ColorMode = CPDF_RenderOptions::kGray; const CPDF_OCContext::UsageType usage = (flags & FPDF_PRINTING) ? CPDF_OCContext::Print : CPDF_OCContext::View; diff --git a/fpdfsdk/fxedit/fxet_edit.cpp b/fpdfsdk/fxedit/fxet_edit.cpp index 82f82477d8..cf382f8426 100644 --- a/fpdfsdk/fxedit/fxet_edit.cpp +++ b/fpdfsdk/fxedit/fxet_edit.cpp @@ -76,14 +76,14 @@ void DrawTextString(CFX_RenderDevice* pDevice, CPDF_RenderOptions ro; ro.m_Flags = RENDER_CLEARTYPE; - ro.m_ColorMode = RENDER_COLOR_NORMAL; + ro.m_ColorMode = CPDF_RenderOptions::kNormal; CPDF_TextRenderer::DrawTextString(pDevice, pos.x, pos.y, pFont, fFontSize, &mt, str, crTextFill, nullptr, &ro); } else { CPDF_RenderOptions ro; ro.m_Flags = RENDER_CLEARTYPE; - ro.m_ColorMode = RENDER_COLOR_NORMAL; + ro.m_ColorMode = CPDF_RenderOptions::kNormal; CPDF_TextRenderer::DrawTextString(pDevice, pos.x, pos.y, pFont, fFontSize, pUser2Device, str, crTextFill, nullptr, |