|typedef QList< TextEntity * >||List|
|TextEntity (const QString &text, NormalizedRect *area)|
|NormalizedRect *||area () const|
|QString||text () const|
|NormalizedRect||transformedArea (const QTransform &matrix) const|
Represents a piece of text on a TextPage, containing its textual representation and its bounding box.
To enable searching and text selection, a generator can give information about the textual content of a Page using a TextPage. A TextPage is created using TextEntity objects. A TextEntity can represent a single character/glyph, a word, a line, or even the whole page.
Ideally, every single glyph is represented by its own TextEntity. If the textual representation of a graphical glyph contains more than one character, the TextEntity must contain the whole string which represents the glyph.
When the Generator has created the TextPage, and it is added to a Page, the text entities are reordered to words, lines, and paragraphs, to optimize search and text selection. This way, the Generator does not need to care about the logical order of lines or paragraphs.
- Text Selection/Highlighting
- A TextEntity is the smallest piece of text, which the user can select, or which can be highlighted. That is, if the TextEntity represents a word, only the whole word can be selected. It would not be possible to select a single glyph of the word, because its bounding box is not known.
Constructor & Destructor Documentation
Member Function Documentation
|NormalizedRect * TextEntity::area||(||)||const|
The documentation for this class was generated from the following files: