PDF SDK Documentation

Comprehensive Guide for Developers: Features, Integration, and API Reference

Loading...
Searching...
No Matches
PDF::PageTextChar Class Reference

Represents a character in a PageText. More...

#include <pdfsdk/cxx/page_text.h>

Public Member Functions

PDF::Quad GetQuad () const
 Get the quad (bounding box) of a character.
 
std::wstring GetUnicode () const
 Get the Unicode representation of a character.
 
float GetRotate () const
 Get the rotation angle of a character within a text element.
 
PDFontInfo GetFontInfo () const
 Get the font information of a character. This includes the font family, style and format.
 
float GetFontSize () const
 Get the font size of a character.
 
PDColorValue GetFontColor () const
 Get the font color of a character.
 

Friends

class PageText
 

Detailed Description

Represents a character in a PageText.

Member Function Documentation

◆ GetFontColor()

PDColorValue PDF::PageTextChar::GetFontColor ( ) const
inline

Get the font color of a character.

Parameters
charindexThe index of the character.
Returns
The font color of the character.

◆ GetFontInfo()

PDFontInfo PDF::PageTextChar::GetFontInfo ( ) const
inline

Get the font information of a character. This includes the font family, style and format.

For more information refer to section 9.5 Introduction to font data structures up to and including section 9.8 Font descriptors from the ISO 32000-2:2020 (PDF 2.0) PDF Standard.

Returns
The font information of the character.

◆ GetFontSize()

float PDF::PageTextChar::GetFontSize ( ) const
inline

Get the font size of a character.

Parameters
charindexThe index of the character.
Returns
The font size of the character.

◆ GetQuad()

PDF::Quad PDF::PageTextChar::GetQuad ( ) const
inline

Get the quad (bounding box) of a character.

For more information characters (glyphs) refer to section 9.2.4 Glyph positioning and metrics and Figure 54 — Glyph metrics of the ISO 32000-2:2020 (PDF 2.0) PDF Standard.

Returns
The quad (bounding box) of the character.

◆ GetRotate()

float PDF::PageTextChar::GetRotate ( ) const
inline

Get the rotation angle of a character within a text element.

This is achieved by reading the transformation matrix associated with the text element.

For more information refer to section 8.3.3 Common transformations of the ISO 32000-2:2020 (PDF 2.0) PDF Standard.

Returns
The rotation angle of the character.

◆ GetUnicode()

std::wstring PDF::PageTextChar::GetUnicode ( ) const
inline

Get the Unicode representation of a character.

For more information refer to Chapter 9.10 Extraction of text content, sections 9.10.1 General and 9.10.2 Mapping character codes to Unicode values of the ISO 32000-2:2020 (PDF 2.0) PDF Standard.

Returns
The Unicode representation of the character.

The documentation for this class was generated from the following file: