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

Unified Diff: fpdfsdk/src/fxedit/fxet_pageobjs.cpp

Issue 1566583002: Merge to XFA: Remove header files that only have includes. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: Fix XFA Created 4 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « fpdfsdk/src/fxedit/fxet_module.cpp ('k') | fpdfsdk/src/pdfwindow/PWL_Button.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/src/fxedit/fxet_pageobjs.cpp
diff --git a/fpdfsdk/src/fxedit/fxet_pageobjs.cpp b/fpdfsdk/src/fxedit/fxet_pageobjs.cpp
index fefa42bdfd079436be116996bf26d88d5944be4a..18687679c24c665120af4056dfeefdc7909a811c 100644
--- a/fpdfsdk/src/fxedit/fxet_pageobjs.cpp
+++ b/fpdfsdk/src/fxedit/fxet_pageobjs.cpp
@@ -4,9 +4,11 @@
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
+#include "core/include/fpdfapi/fpdf_pageobj.h"
+#include "core/include/fpdfapi/fpdf_render.h"
+#include "fpdfsdk/include/fx_systemhandler.h"
#include "fpdfsdk/include/fxedit/fx_edit.h"
#include "fpdfsdk/include/fxedit/fxet_edit.h"
-#include "fpdfsdk/include/fxedit/fxet_stub.h"
#define FX_EDIT_UNDERLINEHALFWIDTH 0.5f
#define FX_EDIT_CROSSOUTHALFWIDTH 0.5f
@@ -57,9 +59,10 @@ static void DrawTextString(CFX_RenderDevice* pDevice,
CPDF_TextRenderer::DrawTextString(pDevice, x, y, pFont, fFontSize, &mt,
str, crTextFill, crTextStroke, &gsd,
&ro);
- } else
+ } else {
CPDF_TextRenderer::DrawTextString(pDevice, x, y, pFont, fFontSize, &mt,
str, crTextFill, 0, NULL, &ro);
+ }
} else {
CPDF_RenderOptions ro;
ro.m_Flags = RENDER_CLEARTYPE;
@@ -76,10 +79,11 @@ static void DrawTextString(CFX_RenderDevice* pDevice,
CPDF_TextRenderer::DrawTextString(pDevice, x, y, pFont, fFontSize,
pUser2Device, str, crTextFill,
crTextStroke, &gsd, &ro);
- } else
+ } else {
CPDF_TextRenderer::DrawTextString(pDevice, x, y, pFont, fFontSize,
pUser2Device, str, crTextFill, 0,
NULL, &ro);
+ }
}
}
}
@@ -218,8 +222,6 @@ void IFX_Edit::DrawEdit(CFX_RenderDevice* pDevice,
word.ptWord.x + word.fWidth,
line.ptLine.y + line.fLineAscent);
rc.Intersect(rcClip);
- // CFX_Edit* pEt = (CFX_Edit*)pEdit;
- // CPDF_Rect rcEdit = pEt->VTToEdit(rc);
pSystemHandler->OutputSelectedRect(pFFLData, rc);
} else {
CFX_PathData pathSelBK;
@@ -282,7 +284,6 @@ void IFX_Edit::DrawRichEdit(CFX_RenderDevice* pDevice,
const CPDF_Rect& rcClip,
const CPDF_Point& ptOffset,
const CPVT_WordRange* pRange) {
- // FX_FLOAT fFontSize = pEdit->GetFontSize();
CPVT_WordRange wrSelect = pEdit->GetSelectWordRange();
FX_COLORREF crCurText = ArgbEncode(255, 0, 0, 0);
@@ -588,17 +589,7 @@ void IFX_Edit::GenerateRichPageObjects(
sTextBuf << GetPDFWordString(pFontMap, word.WordProps.nFontIndex,
word.Word, 0);
- if (word.WordProps.nWordStyle &
- PVTWORD_STYLE_UNDERLINE) { /*
- AddLineToPageObjects(pPageObjects,
- crCurText,
- CPDF_Point(word.ptWord.x,
- word.ptWord.y + word.fDescent *
- 0.4f),
- CPDF_Point(word.ptWord.x
- + word.fWidth, word.ptWord.y +
- word.fDescent * 0.4f));
-*/
+ if (word.WordProps.nWordStyle & PVTWORD_STYLE_UNDERLINE) {
CPDF_Rect rcUnderline = GetUnderLineRect(word);
rcUnderline.left += ptOffset.x;
rcUnderline.right += ptOffset.x;
« no previous file with comments | « fpdfsdk/src/fxedit/fxet_module.cpp ('k') | fpdfsdk/src/pdfwindow/PWL_Button.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698