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

Side by Side Diff: core/include/fpdftext/fpdf_text.h

Issue 1088733002: Kill CFX_Object. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Rebase. Created 5 years, 8 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 unified diff | Download patch
« no previous file with comments | « core/include/fpdfdoc/fpdf_vt.h ('k') | core/include/fxcodec/fx_codec.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 PDFium Authors. All rights reserved. 1 // Copyright 2014 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 6
7 #ifndef _FPDF_TEXT_H_ 7 #ifndef _FPDF_TEXT_H_
8 #define _FPDF_TEXT_H_ 8 #define _FPDF_TEXT_H_
9 #ifndef _FPDF_PARSER_ 9 #ifndef _FPDF_PARSER_
10 #include "../fpdfapi/fpdf_parser.h" 10 #include "../fpdfapi/fpdf_parser.h"
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 #define FPDFTEXT_TBRL 2 52 #define FPDFTEXT_TBRL 2
53 #define FPDFTEXT_LEFT -1 53 #define FPDFTEXT_LEFT -1
54 #define FPDFTEXT_RIGHT 1 54 #define FPDFTEXT_RIGHT 1
55 #define FPDFTEXT_UP -2 55 #define FPDFTEXT_UP -2
56 #define FPDFTEXT_DOWN 2 56 #define FPDFTEXT_DOWN 2
57 class IPDF_ReflowedPage; 57 class IPDF_ReflowedPage;
58 #define FPDFTEXT_WRITINGMODE_UNKNOW 0 58 #define FPDFTEXT_WRITINGMODE_UNKNOW 0
59 #define FPDFTEXT_WRITINGMODE_LRTB 1 59 #define FPDFTEXT_WRITINGMODE_LRTB 1
60 #define FPDFTEXT_WRITINGMODE_RLTB 2 60 #define FPDFTEXT_WRITINGMODE_RLTB 2
61 #define FPDFTEXT_WRITINGMODE_TBRL 3 61 #define FPDFTEXT_WRITINGMODE_TBRL 3
62 class CPDFText_ParseOptions : public CFX_Object 62 class CPDFText_ParseOptions
63 { 63 {
64 public: 64 public:
65 65
66 CPDFText_ParseOptions(); 66 CPDFText_ParseOptions();
67 FX_BOOL m_bGetCharCodeOnly; 67 FX_BOOL m_bGetCharCodeOnly;
68 FX_BOOL m_bNormalizeObjs; 68 FX_BOOL m_bNormalizeObjs;
69 FX_BOOL m_bOutputHyphen; 69 FX_BOOL m_bOutputHyphen;
70 }; 70 };
71 class IPDF_TextPage : public CFX_Object 71 class IPDF_TextPage
72 { 72 {
73 public: 73 public:
74 74
75 virtual ~IPDF_TextPage() {} 75 virtual ~IPDF_TextPage() {}
76 static IPDF_TextPage* CreateTextPage(const CPDF_Page* pPage, CPDFText_ ParseOptions ParserOptions); 76 static IPDF_TextPage* CreateTextPage(const CPDF_Page* pPage, CPDFText_ ParseOptions ParserOptions);
77 static IPDF_TextPage* CreateTextPage(const CPDF_Page* pPage, int flags = 0); 77 static IPDF_TextPage* CreateTextPage(const CPDF_Page* pPage, int flags = 0);
78 static IPDF_TextPage* CreateTextPage(const CPDF_PageObjects* pObjs, in t flags = 0); 78 static IPDF_TextPage* CreateTextPage(const CPDF_PageObjects* pObjs, in t flags = 0);
79 static IPDF_TextPage* CreateReflowTextPage(IPDF_ReflowedPage* pRefPage ); 79 static IPDF_TextPage* CreateReflowTextPage(IPDF_ReflowedPage* pRefPage );
80 80
81 virtual void NormalizeObjects(FX_BOOL bNormalize) = 0 ; 81 virtual void NormalizeObjects(FX_BOOL bNormalize) = 0 ;
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 virtual void GetBoundedSegment(int index, int& start, int& count) const = 0; 123 virtual void GetBoundedSegment(int index, int& start, int& count) const = 0;
124 124
125 125
126 virtual int GetWordBreak(int index, int direction) c onst = 0; 126 virtual int GetWordBreak(int index, int direction) c onst = 0;
127 127
128 virtual CFX_WideString GetPageText(int start = 0, int nCount = -1 ) con st = 0; 128 virtual CFX_WideString GetPageText(int start = 0, int nCount = -1 ) con st = 0;
129 }; 129 };
130 #define FPDFTEXT_MATCHCASE 0x00000001 130 #define FPDFTEXT_MATCHCASE 0x00000001
131 #define FPDFTEXT_MATCHWHOLEWORD 0x00000002 131 #define FPDFTEXT_MATCHWHOLEWORD 0x00000002
132 #define FPDFTEXT_CONSECUTIVE 0x00000004 132 #define FPDFTEXT_CONSECUTIVE 0x00000004
133 class IPDF_TextPageFind : public CFX_Object 133 class IPDF_TextPageFind
134 { 134 {
135 public: 135 public:
136 136
137 virtual ~IPDF_TextPageFind() {} 137 virtual ~IPDF_TextPageFind() {}
138 138
139 static IPDF_TextPageFind* CreatePageFind(const IPDF_TextPage* pTex tPage); 139 static IPDF_TextPageFind* CreatePageFind(const IPDF_TextPage* pTex tPage);
140 public: 140 public:
141 141
142 virtual FX_BOOL FindFirst(const CFX_WideString& findwhat, int flags, int startPos = 0) = 0; 142 virtual FX_BOOL FindFirst(const CFX_WideString& findwhat, int flags, int startPos = 0) = 0;
143 143
144 virtual FX_BOOL FindNext() = 0; 144 virtual FX_BOOL FindNext() = 0;
145 145
146 virtual FX_BOOL FindPrev() = 0; 146 virtual FX_BOOL FindPrev() = 0;
147 147
148 virtual void GetRectArray(CFX_RectArray& rect s) const = 0; 148 virtual void GetRectArray(CFX_RectArray& rect s) const = 0;
149 149
150 virtual int GetCurOrder() const = 0; 150 virtual int GetCurOrder() const = 0;
151 151
152 virtual int GetMatchedCount() const = 0; 152 virtual int GetMatchedCount() const = 0;
153 }; 153 };
154 class IPDF_LinkExtract : public CFX_Object 154 class IPDF_LinkExtract
155 { 155 {
156 public: 156 public:
157 157
158 virtual ~IPDF_LinkExtract() {} 158 virtual ~IPDF_LinkExtract() {}
159 159
160 static IPDF_LinkExtract* CreateLinkExtract(); 160 static IPDF_LinkExtract* CreateLinkExtract();
161 161
162 virtual FX_BOOL ExtractLinks(const IPDF_TextPage * pTextPage) = 0; 162 virtual FX_BOOL ExtractLinks(const IPDF_TextPage * pTextPage) = 0;
163 public: 163 public:
164 164
165 virtual int CountLinks() const = 0; 165 virtual int CountLinks() const = 0;
166 166
167 virtual CFX_WideString GetURL(int index) const = 0; 167 virtual CFX_WideString GetURL(int index) const = 0;
168 168
169 virtual void GetBoundedSegment(int index, int & start, int& count) const = 0; 169 virtual void GetBoundedSegment(int index, int & start, int& count) const = 0;
170 170
171 virtual void GetRects(int index, CFX_RectArra y& rects) const = 0; 171 virtual void GetRects(int index, CFX_RectArra y& rects) const = 0;
172 }; 172 };
173 #endif 173 #endif
OLDNEW
« no previous file with comments | « core/include/fpdfdoc/fpdf_vt.h ('k') | core/include/fxcodec/fx_codec.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698