Foxit PDF SDK
fsdk.TextState Class Reference

Public Member Functions

def GetCharspace ()
 Get character spacing. More...
 
def GetFont ()
 Get a font object. More...
 
def GetFont_horizontal_size ()
 Get font horizontal size in device units (read-only). More...
 
def GetFont_size ()
 Get the font size in "Tf". More...
 
def GetFont_vertical_size ()
 Get font vertical size in device units (read-only). More...
 
def GetOrigin_position ()
 Get the origin point, in [PDF coordinate system] (). More...
 
def GetTextmode ()
 Get text rendering mode. More...
 
def GetVersion ()
 Get version of this class. More...
 
def GetWordspace ()
 Get word spacing (only apply to space character). More...
 
def SetCharspace (value)
 Set character spacing. More...
 
def SetFont (value)
 Set a font object. More...
 
def SetFont_horizontal_size (value)
 Set font horizontal size in device units (read-only). More...
 
def SetFont_size (value)
 Set the font size in "Tf". More...
 
def SetFont_vertical_size (value)
 Set font vertical size in device units (read-only). More...
 
def SetOrigin_position (value)
 Set the origin point, in [PDF coordinate system] (). More...
 
def SetTextmode (value)
 Set text rendering mode. More...
 
def SetVersion (value)
 Set version of this class. More...
 
def SetWordspace (value)
 Set word spacing (only apply to space character). More...
 

Detailed Description

This class represents PDF text state.

Member Function Documentation

◆ GetCharspace()

fsdk.TextState.GetCharspace ( )

Get character spacing.

For horizontal writing, a positive value has the effect of expanding the distance between glyphs, whereas for vertical writing, a negative value has this effect.

Returns
Character spacing.

◆ GetFont()

fsdk.TextState.GetFont ( )

Get a font object.

Returns
A font object.

◆ GetFont_horizontal_size()

fsdk.TextState.GetFont_horizontal_size ( )

Get font horizontal size in device units (read-only).

Returns
Font horizontal size in device units (read-only). If valid, it would be above 0.

◆ GetFont_size()

fsdk.TextState.GetFont_size ( )

Get the font size in "Tf".

Returns
The font size in "Tf". If valid, it should be above 0.

◆ GetFont_vertical_size()

fsdk.TextState.GetFont_vertical_size ( )

Get font vertical size in device units (read-only).

Returns
Font vertical size in device units (read-only). If valid, it would be above 0.

◆ GetOrigin_position()

fsdk.TextState.GetOrigin_position ( )

Get the origin point, in [PDF coordinate system] ().

Returns
The origin point, in [PDF coordinate system] ().

◆ GetTextmode()

fsdk.TextState.GetTextmode ( )

Get text rendering mode.

Returns
Text rendering mode. Please refer to values starting from fsdk.TextStateE_ModeFill and this should be one of these values.

◆ GetVersion()

fsdk.TextState.GetVersion ( )

Get version of this class.

Members of this class may be extended in the future. This version can be used to separate the different extended members.

Returns
Version of this class.

◆ GetWordspace()

fsdk.TextState.GetWordspace ( )

Get word spacing (only apply to space character).

For horizontal writing, a positive value has the effect of increasing the spacing between words. For vertical writing, a positive value decreases the spacing between words (and a negative value increases it), since vertical coordinates increase from bottom to top. This will not take effect if font of current object is an embedded font.

Returns
Word spacing (only apply to space character).

◆ SetCharspace()

fsdk.TextState.SetCharspace (   value)

Set character spacing.

For horizontal writing, a positive value has the effect of expanding the distance between glyphs, whereas for vertical writing, a negative value has this effect.

Parameters
[in]valueCharacter spacing.
Returns
None.

◆ SetFont()

fsdk.TextState.SetFont (   value)

Set a font object.

Parameters
[in]valueA font object.
Returns
None.

◆ SetFont_horizontal_size()

fsdk.TextState.SetFont_horizontal_size (   value)

Set font horizontal size in device units (read-only).

Parameters
[in]valueFont horizontal size in device units (read-only). If valid, it would be above 0.
Returns
None.

◆ SetFont_size()

fsdk.TextState.SetFont_size (   value)

Set the font size in "Tf".

Parameters
[in]valueThe font size in "Tf". If valid, it should be above 0.
Returns
None.

◆ SetFont_vertical_size()

fsdk.TextState.SetFont_vertical_size (   value)

Set font vertical size in device units (read-only).

Parameters
[in]valueFont vertical size in device units (read-only). If valid, it would be above 0.
Returns
None.

◆ SetOrigin_position()

fsdk.TextState.SetOrigin_position (   value)

Set the origin point, in [PDF coordinate system] ().

Parameters
[in]valueThe origin point, in [PDF coordinate system] ().
Returns
None.

◆ SetTextmode()

fsdk.TextState.SetTextmode (   value)

Set text rendering mode.

Parameters
[in]valueText rendering mode. Please refer to values starting from fsdk.TextStateE_ModeFill and this should be one of these values.
Returns
None.

◆ SetVersion()

fsdk.TextState.SetVersion (   value)

Set version of this class.

Members of this class may be extended in the future. This version can be used to separate the different extended members.

Parameters
[in]valueVersion of this class.
Returns
None.

◆ SetWordspace()

fsdk.TextState.SetWordspace (   value)

Set word spacing (only apply to space character).

For horizontal writing, a positive value has the effect of increasing the spacing between words. For vertical writing, a positive value decreases the spacing between words (and a negative value increases it), since vertical coordinates increase from bottom to top. This will not take effect if font of current object is an embedded font.

Parameters
[in]valueWord spacing (only apply to space character).
Returns
None.