TextState Class Documentation
class TextStateNamespace:datalogics_interface
Detailed Description
The text state includes parameters that affect text.
These parameters include character and word spacing, font, font size, and horizontal scale.
Referenced by
Uses types
Constructor & Destructor Documentation
TextState
TextState()Create a default text state.
TextState
TextState(const TextState & )Parameters
Copy constructor.
TextState
TextState(TextState && )Parameters
~TextState
~TextState()Member Function Documentation
get_character_spacing
double get_character_spacing()Returns:
doubleThe current character spacing (corresponding to the Tc operator), in unscaled text space units.
get_font_size
double get_font_size()Returns:
doubleThe current font size (corresponding to the Tf operator).
get_horizontal_scale
double get_horizontal_scale()Returns:
doubleThe current horizontal scaling (corresponding to the Tz operator), as a percentage of the normal glyph width. Default is 100.
get_render_mode
TextRenderMode get_render_mode()Returns:
TextRenderModeThe current text rendering mode (corresponding to the Tr operator).
get_text_rise
double get_text_rise()Returns:
doubleThe current text rise (corresponding to the Ts operator), in unscaled text space units.
get_word_spacing
double get_word_spacing()Returns:
doubleThe current word spacing (corresponding to the Tw operator), in unscaled text space units.
operator=
TextState & operator=(const TextState & )Parameters
Returns:
TextState &Copy assignment.
operator=
TextState & operator=(TextState && )Parameters
Returns:
TextState &set_character_spacing
void set_character_spacing(double spacing)Parameters
spacing: double- the new/updated character spacing
Returns:
voidThe current character spacing (corresponding to the Tc operator), in unscaled text space units.
set_font_size
void set_font_size(double size)Parameters
size: double- the new/updated font size
Returns:
voidThe current font size (corresponding to the Tf operator).
set_horizontal_scale
void set_horizontal_scale(double scale)Parameters
scale: double- the new/updated horizontal scaling
Returns:
voidThe current horizontal scaling (corresponding to the Tz operator), as a percentage of the normal glyph width. Default is 100.
set_render_mode
void set_render_mode(TextRenderMode mode)Parameters
mode: TextRenderMode- the new/updated text rendering mode
Returns:
voidThe current text rendering mode (corresponding to the Tr operator).
set_text_rise
void set_text_rise(double rise)Parameters
rise: double- the new/updated text rise
Returns:
voidThe current text rise (corresponding to the Ts operator), in unscaled text space units.
set_word_spacing
void set_word_spacing(double spacing)Parameters
spacing: double- the new/updated character spacing
Returns:
voidThe current word spacing (corresponding to the Tw operator), in unscaled text space units.