summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2017-03-01 13:18:50 -0800
committerChromium commit bot <commit-bot@chromium.org>2017-03-01 22:13:37 +0000
commite65d62cb8a67b776439142ee4a62cc0c3cd66f08 (patch)
treeae7a2dc519f3f2567988aa4b99f7673417cd853e
parentb0d3160afa3ee0190b497d0eced5f5de1fdc8fbb (diff)
downloadpdfium-e65d62cb8a67b776439142ee4a62cc0c3cd66f08.tar.xz
Remove unused FX_AdjustCharDisplayPos type, always nullptr args
Found while looking for c-style callbacks. Change-Id: If21ad273e23eb83c25297e9fc123c3a2228fed70 Reviewed-on: https://pdfium-review.googlesource.com/2893 Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Tom Sepez <tsepez@chromium.org>
-rw-r--r--xfa/fgas/layout/fgas_textbreak.cpp10
-rw-r--r--xfa/fgas/layout/fgas_textbreak.h3
-rw-r--r--xfa/fgas/layout/fgas_unicode.h8
3 files changed, 3 insertions, 18 deletions
diff --git a/xfa/fgas/layout/fgas_textbreak.cpp b/xfa/fgas/layout/fgas_textbreak.cpp
index 69baa14c6c..ad7ab91598 100644
--- a/xfa/fgas/layout/fgas_textbreak.cpp
+++ b/xfa/fgas/layout/fgas_textbreak.cpp
@@ -1143,8 +1143,7 @@ struct FX_FORMCHAR {
int32_t CFX_TxtBreak::GetDisplayPos(const FX_TXTRUN* pTxtRun,
FXTEXT_CHARPOS* pCharPos,
bool bCharCode,
- CFX_WideString* pWSForms,
- FX_AdjustCharDisplayPos pAdjustPos) const {
+ CFX_WideString* pWSForms) const {
if (!pTxtRun || pTxtRun->iLength < 1)
return 0;
@@ -1422,12 +1421,7 @@ int32_t CFX_TxtBreak::GetDisplayPos(const FX_TXTRUN* pTxtRun,
}
}
CFX_PointF ptOffset;
- bool bAdjusted = false;
- if (pAdjustPos) {
- bAdjusted = pAdjustPos(wForm, bCharCode, pFont, fFontSize,
- bVerticalChar, ptOffset);
- }
- if (!bAdjusted && bVerticalChar && (dwProps & 0x00010000) != 0) {
+ if (bVerticalChar && (dwProps & 0x00010000) != 0) {
CFX_Rect rtBBox;
if (pFont->GetCharBBox(wForm, &rtBBox, false)) {
ptOffset.x = fFontSize * (850 - rtBBox.right()) / iMaxHeight;
diff --git a/xfa/fgas/layout/fgas_textbreak.h b/xfa/fgas/layout/fgas_textbreak.h
index a217d1636e..cadfcf12bc 100644
--- a/xfa/fgas/layout/fgas_textbreak.h
+++ b/xfa/fgas/layout/fgas_textbreak.h
@@ -227,8 +227,7 @@ class CFX_TxtBreak {
int32_t GetDisplayPos(const FX_TXTRUN* pTxtRun,
FXTEXT_CHARPOS* pCharPos,
bool bCharCode = false,
- CFX_WideString* pWSForms = nullptr,
- FX_AdjustCharDisplayPos pAdjustPos = nullptr) const;
+ CFX_WideString* pWSForms = nullptr) const;
int32_t GetCharRects(const FX_TXTRUN* pTxtRun,
std::vector<CFX_RectF>* rtArray,
bool bCharBBox = false) const;
diff --git a/xfa/fgas/layout/fgas_unicode.h b/xfa/fgas/layout/fgas_unicode.h
index b404d6728a..0a1fbfe440 100644
--- a/xfa/fgas/layout/fgas_unicode.h
+++ b/xfa/fgas/layout/fgas_unicode.h
@@ -18,12 +18,4 @@ typedef CFX_MassArrayTemplate<FX_TPO> CFX_TPOArray;
void FX_TEXTLAYOUT_PieceSort(CFX_TPOArray& tpos, int32_t iStart, int32_t iEnd);
-typedef bool (*FX_AdjustCharDisplayPos)(
- FX_WCHAR wch,
- bool bMBCSCode,
- const CFX_RetainPtr<CFGAS_GEFont>& pFont,
- FX_FLOAT fFontSize,
- bool bVertical,
- CFX_PointF& ptOffset);
-
#endif // XFA_FGAS_LAYOUT_FGAS_UNICODE_H_