summaryrefslogtreecommitdiff
path: root/core/src/fpdftext/txtproc.h
diff options
context:
space:
mode:
authorNico Weber <thakis@chromium.org>2015-08-04 12:19:10 -0700
committerNico Weber <thakis@chromium.org>2015-08-04 12:19:10 -0700
commitb048f791a15f2da781a01eba5b09eb9d389f9c11 (patch)
tree6850a73c18bbc41eaf4b1fdc6b3c96646d45587b /core/src/fpdftext/txtproc.h
parentc8eeed31f217d99a706b0cbf5e4ce0bcc12beb64 (diff)
downloadpdfium-b048f791a15f2da781a01eba5b09eb9d389f9c11.tar.xz
clang-format all pdfium code.
No behavior change. Generated by: find . -name '*.cpp' -o -name '*.h' | \ grep -E -v 'third_party|thirdparties|lpng_v163' | \ xargs ../../buildtools/mac/clang-format -i See thread "tabs vs spaces" on pdfium@googlegroups.com for discussion. BUG=none R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1265503005 .
Diffstat (limited to 'core/src/fpdftext/txtproc.h')
-rw-r--r--core/src/fpdftext/txtproc.h119
1 files changed, 65 insertions, 54 deletions
diff --git a/core/src/fpdftext/txtproc.h b/core/src/fpdftext/txtproc.h
index 275aabd53b..22088f2450 100644
--- a/core/src/fpdftext/txtproc.h
+++ b/core/src/fpdftext/txtproc.h
@@ -7,66 +7,77 @@
#ifndef CORE_SRC_FPDFTEXT_TXTPROC_H_
#define CORE_SRC_FPDFTEXT_TXTPROC_H_
-class CTextColumn
-{
-public:
- FX_FLOAT m_AvgPos;
- int m_Count;
- int m_TextPos;
+class CTextColumn {
+ public:
+ FX_FLOAT m_AvgPos;
+ int m_Count;
+ int m_TextPos;
};
-class CTextBox
-{
-public:
- CFX_WideString m_Text;
- FX_FLOAT m_Left;
- FX_FLOAT m_Right;
- FX_FLOAT m_SpaceWidth;
- FX_FLOAT m_Top;
- FX_FLOAT m_Bottom;
- FX_FLOAT m_FontSizeV;
- CTextColumn* m_pColumn;
+class CTextBox {
+ public:
+ CFX_WideString m_Text;
+ FX_FLOAT m_Left;
+ FX_FLOAT m_Right;
+ FX_FLOAT m_SpaceWidth;
+ FX_FLOAT m_Top;
+ FX_FLOAT m_Bottom;
+ FX_FLOAT m_FontSizeV;
+ CTextColumn* m_pColumn;
};
-class CTextBaseLine
-{
-public:
- CTextBaseLine();
- ~CTextBaseLine();
- void InsertTextBox(FX_FLOAT leftx, FX_FLOAT rightx, FX_FLOAT topy, FX_FLOAT bottomy,
- FX_FLOAT spacew, FX_FLOAT fontsize_v, const CFX_WideString& str);
- FX_BOOL GetWidth(FX_FLOAT& leftx, FX_FLOAT& rightx);
- FX_BOOL CanMerge(CTextBaseLine* pOther);
- void Merge(CTextBaseLine* pOther);
- void MergeBoxes();
- void CountChars(int& count, FX_FLOAT& width, int& minchars);
- void WriteOutput(CFX_WideString& str, FX_FLOAT leftx, FX_FLOAT width, int iWidth);
- FX_FLOAT m_BaseLine;
- FX_FLOAT m_Top;
- FX_FLOAT m_Bottom;
- FX_FLOAT m_MaxFontSizeV;
- CFX_PtrArray m_TextList;
+class CTextBaseLine {
+ public:
+ CTextBaseLine();
+ ~CTextBaseLine();
+ void InsertTextBox(FX_FLOAT leftx,
+ FX_FLOAT rightx,
+ FX_FLOAT topy,
+ FX_FLOAT bottomy,
+ FX_FLOAT spacew,
+ FX_FLOAT fontsize_v,
+ const CFX_WideString& str);
+ FX_BOOL GetWidth(FX_FLOAT& leftx, FX_FLOAT& rightx);
+ FX_BOOL CanMerge(CTextBaseLine* pOther);
+ void Merge(CTextBaseLine* pOther);
+ void MergeBoxes();
+ void CountChars(int& count, FX_FLOAT& width, int& minchars);
+ void WriteOutput(CFX_WideString& str,
+ FX_FLOAT leftx,
+ FX_FLOAT width,
+ int iWidth);
+ FX_FLOAT m_BaseLine;
+ FX_FLOAT m_Top;
+ FX_FLOAT m_Bottom;
+ FX_FLOAT m_MaxFontSizeV;
+ CFX_PtrArray m_TextList;
};
class CPDF_PageObject;
class CPDF_TextObject;
-class CTextPage
-{
-public:
- CTextPage();
- ~CTextPage();
- void ProcessObject(CPDF_PageObject* pObj);
- CTextBaseLine* InsertTextBox(CTextBaseLine* pBaseLine, FX_FLOAT basey, FX_FLOAT leftx,
- FX_FLOAT rightx, FX_FLOAT topy, FX_FLOAT bottomy, FX_FLOAT spacew, FX_FLOAT fontsize_v,
- CFX_ByteString& str, CPDF_Font* pFont);
- void WriteOutput(CFX_WideStringArray& lines, int iMinWidth);
- FX_BOOL m_bAutoWidth;
- FX_BOOL m_bKeepColumn;
- FX_BOOL m_bBreakSpace;
+class CTextPage {
+ public:
+ CTextPage();
+ ~CTextPage();
+ void ProcessObject(CPDF_PageObject* pObj);
+ CTextBaseLine* InsertTextBox(CTextBaseLine* pBaseLine,
+ FX_FLOAT basey,
+ FX_FLOAT leftx,
+ FX_FLOAT rightx,
+ FX_FLOAT topy,
+ FX_FLOAT bottomy,
+ FX_FLOAT spacew,
+ FX_FLOAT fontsize_v,
+ CFX_ByteString& str,
+ CPDF_Font* pFont);
+ void WriteOutput(CFX_WideStringArray& lines, int iMinWidth);
+ FX_BOOL m_bAutoWidth;
+ FX_BOOL m_bKeepColumn;
+ FX_BOOL m_bBreakSpace;
-private:
- CFX_PtrArray m_BaseLines;
- CFX_PtrArray m_TextColumns;
- void FindColumns();
- CTextColumn* FindColumn(FX_FLOAT xpos);
- void BreakSpace(CPDF_TextObject* pTextObj);
+ private:
+ CFX_PtrArray m_BaseLines;
+ CFX_PtrArray m_TextColumns;
+ void FindColumns();
+ CTextColumn* FindColumn(FX_FLOAT xpos);
+ void BreakSpace(CPDF_TextObject* pTextObj);
};
#endif // CORE_SRC_FPDFTEXT_TXTPROC_H_