summaryrefslogtreecommitdiff
path: root/xfa/fgas/layout/cfx_break.h
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2017-03-21 11:31:25 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-03-21 15:55:35 +0000
commit5c529e6318d46121a5ea38d3edb42c8d9f580fe8 (patch)
treef11ae317bb4cdb94e69e9b1ae1a6db6342218b61 /xfa/fgas/layout/cfx_break.h
parenta766a958c5867a2a5562095ad03f72290db18b98 (diff)
downloadpdfium-5c529e6318d46121a5ea38d3edb42c8d9f580fe8.tar.xz
Combine more RTF and TXT Break code
This Cl conbines several more methods from RTFBreak and TXTBreak into the common Break baseclass. Change-Id: Ibe2236eb4fd30faab239e7c9c8b578164014eb39 Reviewed-on: https://pdfium-review.googlesource.com/3108 Reviewed-by: Nicolás Peña <npm@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'xfa/fgas/layout/cfx_break.h')
-rw-r--r--xfa/fgas/layout/cfx_break.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/xfa/fgas/layout/cfx_break.h b/xfa/fgas/layout/cfx_break.h
index 631cc5aaa1..4a7185bd70 100644
--- a/xfa/fgas/layout/cfx_break.h
+++ b/xfa/fgas/layout/cfx_break.h
@@ -50,14 +50,23 @@ class CFX_Break {
void SetParagraphBreakChar(wchar_t wch);
void SetDefaultChar(wchar_t wch);
- virtual void SetBreakStatus() = 0;
+ int32_t CountBreakPieces() const;
+ const CFX_BreakPiece* GetBreakPieceUnstable(int32_t index) const;
+ void ClearBreakPieces();
+
+ CFX_Char* GetLastChar(int32_t index, bool bOmitChar, bool bRichText) const;
protected:
explicit CFX_Break(uint32_t dwLayoutStyles);
+ void SetBreakStatus();
+ bool HasLine() const { return m_iReadyLineIndex >= 0; }
+ FX_CHARTYPE GetUnifiedCharType(FX_CHARTYPE dwType) const;
+
FX_CHARTYPE m_eCharType;
bool m_bSingleLine;
bool m_bCombText;
+ uint32_t m_dwIdentity;
uint32_t m_dwLayoutStyles;
int32_t m_iLineStart;
int32_t m_iLineWidth;