Go to the documentation of this file.
23 #endif // #ifndef _FX_NO_XFA_
58 typedef enum _TextCharFlag {
272 typedef enum _TextParseFlags {
286 typedef enum _TextOrderFlag {
520 typedef enum _SearchFlags {
564 #endif // #ifndef _FX_NO_XFA_
635 bool SetPattern(
const wchar_t* key_words,
bool is_regex_search =
false);
953 #endif // FS_SEARCH_H_
TextParseFlags
Enumeration for parsing flags used for text page.
Definition: fs_search.h:272
If set, match the case of keyword when searching.
Definition: fs_search.h:524
bool IsEmpty() const
Check whether current object is empty or not.
Definition: fs_search.h:881
If this is set, that means to get text content of a PDF page by the stream order.
Definition: fs_search.h:288
float origin_x
The x-coordinate of the origin position.
Definition: fs_search.h:227
RectF char_box
The glyph bounding box in page space.
Definition: fs_search.h:237
void * FS_HANDLE
Handle type.
Definition: fs_basictypes.h:213
Parse the text content of a PDF page with outputting the hyphen on a line feed.
Definition: fs_search.h:276
RectFArray GetTextRectArrayByRect(const RectF &rect)
Get the array of all text rectangles within the specified rectangle region.
Definition: fs_annot.h:1006
common::Font font
A font for character.
Definition: fs_search.h:207
int GetCharCount() const
Get the count of all the characters.
bool IsEmpty() const
Check whether current object is empty or not.
bool SetEndPage(int page_index)
Set ending page index.
int GetStartCharIndex()
Get the index of start character of current hyper-link URI, based on PDF page.
bool operator!=(const TextSearch &other) const
Not equal operator.
CFX_Object Object
Object type.
Definition: fs_basictypes.h:220
TextCharFlag flag
Flags to indicate which properties of textpage character flag are meaningful.
Definition: fs_search.h:215
int GetMatchStartCharIndex() const
Get the index of the first character of current match pattern, based on current match page.
Matrix matrix
The matrix of the character.
Definition: fs_search.h:247
TextPage & operator=(const TextPage &other)
Assign operator.
virtual bool NeedToCancelNow()=0
A callback function used to check whether to cancel the searching process or not.
bool operator==(const TextLink &other) const
Equal operator.
float origin_y
The y-coordinate of the origin position.
Definition: fs_search.h:232
RectF GetTextRect(int rect_index) const
Get the text rectangle by the index.
If this is set, that means to get text content of a PDF page by the display order.
Definition: fs_search.h:290
Definition: fs_search.h:265
common::Range GetWordAtPos(float x, float y, float tolerance) const
Get the character range of a word at or around a specified position on the page, in PDF coordinate sy...
Character flag: Hyphen.
Definition: fs_search.h:68
Header file for common definitions and classes.
RectFArray GetMatchRects() const
Get the rectangles of current match pattern.
RectFArray GetRects()
Get the text rectangles of current text link object.
Character flag: Generated.
Definition: fs_search.h:64
RectF char_outbox
The typographic(display and printing) bounding box in page space.
Definition: fs_search.h:242
PageTextLinks & operator=(const PageTextLinks &other)
Assign operator.
common::Rotation GetBaselineRotation(int rect_index)
Get the text trend (as rotation) of a specified rectangle.
common::Range GetCharRange(const RectF &rect)
Get the character index range of all text rectangles within the specified rectangle region.
TextLink & operator=(const TextLink &other)
Assign operator.
int GetMatchEndCharIndex() const
Get the index of the last character of current match pattern, based on current match page.
bool operator==(const TextSearch &other) const
Equal operator.
Definition: fs_search.h:51
Parse the text content of a PDF page by the stream order.
Definition: fs_search.h:278
bool IsEmpty() const
Check whether current object is empty or not.
WString GetText(TextOrderFlag flag) const
Get the page text.
bool SetStartCharacter(int char_index)
Set starting character index, from where the search process is to be started.
bool FindPrev()
Search for previous matched pattern.
TextPageCharInfo(const TextPageCharInfo &char_info)
Constructor, with another character information object.
Definition: fs_search.h:113
float font_size
Font size for character.
Definition: fs_search.h:222
Header file for XFA related definitions and functions.
TextPageCharInfo & operator=(const TextPageCharInfo &char_info)
Assign operator.
Definition: fs_search.h:131
Character flag: UnUnicode.
Definition: fs_search.h:66
WString GetChars(int start=0, int count=-1) const
Get all the characters within a range specified by a start index and count.
int GetMatchPageIndex() const
Get the page index, to which current match belongs.
WString GetURI()
Get URI string.
bool SetStartPage(int page_index)
Set starting page index.
int GetIndexAtPos(float x, float y, float tolerance) const
Get the character index at or around a specified position on the page, in PDF coordinate system.
bool operator!=(const TextLink &other) const
Not equal operator.
Rotation
Enumeration for rotation.
Definition: fs_common.h:57
bool operator!=(const PageTextLinks &other) const
Not equal operator.
TextLink(const TextLink &other)
Constructor, with another text link object.
Character flag: Normal.
Definition: fs_search.h:62
If set, match the whole word of keyword when searching.
Definition: fs_search.h:526
int GetTextLinkCount()
Get the count of the URL formatted texts, in related PDF page.
If set, match the key word consecutively when searching. For example, "CC" will be matched twice in "...
Definition: fs_search.h:528
TextCharFlag
Enumeration for PDF textpage character flag.
Definition: fs_search.h:58
Header file for PDF page related definitions and classes.
int GetEndCharIndex()
Get the index of last character of current hyper-link URI, based on PDF page.
Foxit namespace.
Definition: fs_taggedpdf.h:27
Parse the text content of a PDF page by normalizing characters based on their positions in the PDF pa...
Definition: fs_search.h:274
TextPage(const PDFPage &page, int flags=foxit::pdf::TextPage::e_ParseTextNormal)
Constructor, from a parsed PDF page.
TextSearch & operator=(const TextSearch &other)
Assign operator.
WString GetTextInRect(const RectF &rect) const
Get the text within a rectangle, in PDF coordinate system.
TextPageCharInfo(const common::Font &font, TextCharFlag flag, float font_size, float origin_x, float origin_y, const RectF &char_box, const RectF &char_outbox, const Matrix &matrix)
Constructor, with parameters.
Definition: fs_search.h:89
bool SetPattern(const wchar_t *key_words, bool is_regex_search=false)
Set keywords to search.
bool FindNext()
Search for next matched pattern.
TextPageCharInfo()
Constructor.
Definition: fs_search.h:102
bool operator==(const PageTextLinks &other) const
Equal operator.
bool IsEmpty() const
Check whether current object is empty or not.
#define NULL
The null-pointer value.
Definition: fx_system.h:792
No special searching options.
Definition: fs_search.h:522
Definition: fx_coordinates.h:771
void Set(const common::Font &font, TextCharFlag flag, float font_size, float origin_x, float origin_y, const RectF &char_box, const RectF &char_outbox, const Matrix &matrix)
Set value.
Definition: fs_search.h:192
SearchFlags
Enumeration for searching flags.
Definition: fs_search.h:520
Definition: fs_search.h:513
Definition: fs_pdfdoc.h:776
Definition: fs_pdfpage.h:412
~PageTextLinks()
Destructor.
Definition: fs_search.h:39
Character flag: Unknown.
Definition: fs_search.h:60
TextSearch(const PDFDoc &document, SearchCancelCallback *cancel=0, int flags=foxit::pdf::TextPage::e_ParseTextNormal)
Constructor, for a PDF document.
Character flag: ComboWord.
Definition: fs_search.h:70
bool SetSearchFlags(uint32 search_flags)
Set search flags.
Definition: fs_common.h:1523
Definition: fx_coordinates.h:1076
If set, to ignore full-width characters and treat all characters as standard ASCII or standard-width ...
Definition: fs_search.h:530
Header file for annotation related definitions and classes.
int GetMatchSentenceEndIndex()
Get the index of the last character of current matched pattern, based on the matched sentence.
bool operator==(const TextPageCharInfo &char_info) const
Equal operator.
Definition: fs_search.h:150
WIDE STRING CLASS.
Definition: fx_string.h:1461
WString GetMatchSentence()
Get the sentence that contains current match pattern.
Definition: fs_common.h:1368
WString GetTextUnderAnnot(annots::Annot &annot) const
Get the page text which intersect with a specified an annotation.
Definition: fs_search.h:797
int GetTextRectCount(int start=0, int count=-1)
Count the text rectangles within a range specified by a start index and count.
FX_UINT32 uint32
32-bit unsigned integer.
Definition: fs_basictypes.h:195
bool operator!=(const TextPage &other) const
Not equal operator.
PageTextLinks(const TextPage &page)
Constructor, from a parsed PDF page.
int GetMatchSentenceStartIndex()
Get the index of the first character of current matched pattern, based on the matched sentence.
Definition: fs_basictypes.h:451
bool operator==(const TextPage &other) const
Equal operator.
TextOrderFlag
Enumeration for text order flag which is used when getting text content of a PDF page.
Definition: fs_search.h:286
TextLink GetTextLink(int index)
Get a text link object by index.
TextPageCharInfo GetCharInfo(int char_index)
Get character information of a specific character.
bool operator!=(const TextPageCharInfo &char_info) const
Not equal operator.
Definition: fs_search.h:166
@2026 Foxit Software Incorporated. All rights reserved.