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

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

Issue 1737593006: Re-land "Replace CPDF_Rect and CPDF_Point with CFX types." (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Ooops. Created 4 years, 10 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/fsdk_mgr.cpp ('k') | fpdfsdk/src/fxedit/fxet_edit.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/src/fxedit/fxet_ap.cpp
diff --git a/fpdfsdk/src/fxedit/fxet_ap.cpp b/fpdfsdk/src/fxedit/fxet_ap.cpp
index 2803b60d728de00f6b492958c6be0f38e0e08b90..562f566edbff7bdd7e91de0d5bcd86a8f0bd9618 100644
--- a/fpdfsdk/src/fxedit/fxet_ap.cpp
+++ b/fpdfsdk/src/fxedit/fxet_ap.cpp
@@ -60,13 +60,13 @@ static CFX_ByteString GetFontSetString(IFX_Edit_FontMap* pFontMap,
CFX_ByteString IFX_Edit::GetEditAppearanceStream(
IFX_Edit* pEdit,
- const CPDF_Point& ptOffset,
+ const CFX_FloatPoint& ptOffset,
const CPVT_WordRange* pRange /* = NULL*/,
FX_BOOL bContinuous /* = TRUE*/,
FX_WORD SubWord /* = 0*/) {
CFX_ByteTextBuf sEditStream, sWords;
- CPDF_Point ptOld(0.0f, 0.0f), ptNew(0.0f, 0.0f);
+ CFX_FloatPoint ptOld(0.0f, 0.0f), ptNew(0.0f, 0.0f);
int32_t nCurFontIndex = -1;
if (IFX_Edit_Iterator* pIterator = pEdit->GetIterator()) {
@@ -92,13 +92,13 @@ CFX_ByteString IFX_Edit::GetEditAppearanceStream(
CPVT_Word word;
if (pIterator->GetWord(word)) {
- ptNew = CPDF_Point(word.ptWord.x + ptOffset.x,
- word.ptWord.y + ptOffset.y);
+ ptNew = CFX_FloatPoint(word.ptWord.x + ptOffset.x,
+ word.ptWord.y + ptOffset.y);
} else {
CPVT_Line line;
pIterator->GetLine(line);
- ptNew = CPDF_Point(line.ptLine.x + ptOffset.x,
- line.ptLine.y + ptOffset.y);
+ ptNew = CFX_FloatPoint(line.ptLine.x + ptOffset.x,
+ line.ptLine.y + ptOffset.y);
}
if (ptNew.x != ptOld.x || ptNew.y != ptOld.y) {
@@ -129,8 +129,8 @@ CFX_ByteString IFX_Edit::GetEditAppearanceStream(
} else {
CPVT_Word word;
if (pIterator->GetWord(word)) {
- ptNew = CPDF_Point(word.ptWord.x + ptOffset.x,
- word.ptWord.y + ptOffset.y);
+ ptNew = CFX_FloatPoint(word.ptWord.x + ptOffset.x,
+ word.ptWord.y + ptOffset.y);
if (ptNew.x != ptOld.x || ptNew.y != ptOld.y) {
sEditStream << ptNew.x - ptOld.x << " " << ptNew.y - ptOld.y
@@ -176,7 +176,7 @@ CFX_ByteString IFX_Edit::GetEditAppearanceStream(
CFX_ByteString IFX_Edit::GetSelectAppearanceStream(
IFX_Edit* pEdit,
- const CPDF_Point& ptOffset,
+ const CFX_FloatPoint& ptOffset,
const CPVT_WordRange* pRange) {
CFX_ByteTextBuf sRet;
« no previous file with comments | « fpdfsdk/src/fsdk_mgr.cpp ('k') | fpdfsdk/src/fxedit/fxet_edit.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698