Skip to content

PDFStringLayoutOptions

Namespace: O2S.Components.PDF4NET.Graphics

Defines various layout options for displaying text on page graphics.

public class PDFStringLayoutOptions

Inheritance ObjectPDFStringLayoutOptions

Constructors

PDFStringLayoutOptions()

Initializes a new PDFStringLayoutOptions object.

public PDFStringLayoutOptions()

PDFStringLayoutOptions(PDFStringLayoutOptions)

Initializes a new PDFStringLayoutOptions object.

public PDFStringLayoutOptions(PDFStringLayoutOptions source)

Parameters

source PDFStringLayoutOptions
Source layout options for initializing this object.


Properties

ForceLongWordsWrap

Gets or sets a flag indicating whether long words should wrap if they do not fit entirely on a single line.

public bool ForceLongWordsWrap { get; set; }

Property Value

Boolean
True if long words are wrapped at character level if they do not fit entirely on a single line.


Height

Gets or sets the height of rectangle that defines the text location.

public double Height { get; set; }

Property Value

Double
The height of text rectangle.

Remarks

The text is cut when its height is greater than this height. If this property is 0 or negative, its value is ignored and the text overflows.


HorizontalAlign

Gets or sets the horizontal alignment of text.

public PDFStringHorizontalAlign HorizontalAlign { get; set; }

Property Value

PDFStringHorizontalAlign
Text horizontal alignment.


LineSpacingAdjustment

Gets or sets the line spacing adjustment.

public double LineSpacingAdjustment { get; set; }

Property Value

Double
Adjustment of the default line spacing.

Remarks

This property is added to default line spacing in order to increase or decrease the spacing between lines of text in a text box.


Rotation

Gets or sets the rotation angle of the text.

public double Rotation { get; set; }

Property Value

Double
Text rotation angle in degrees.

Remarks

The text is rotated counterclockwise.


TextDirection

Gets or sets the text direction.

public PDFTextDirection TextDirection { get; set; }

Property Value

PDFTextDirection
The direction of the written text.


VerticalAlign

Gets or sets the vertical alignment of text.

public PDFStringVerticalAlign VerticalAlign { get; set; }

Property Value

PDFStringVerticalAlign
Vertical text alignment.


Width

Gets or sets the width of rectangle that defines the text location.

public double Width { get; set; }

Property Value

Double
The width of text rectangle.

Remarks

The text is automatically wrapped when the text width is greater than this width. If this property is 0 or negative, its value is ignored and the text is not wrapped.


X

Gets or sets the X coordinate of the text anchor point.

public double X { get; set; }

Property Value

Double
X coordinate of text anchor point.

Remarks

The anchor point depends on the horizontal text alignment.


Y

Gets or sets the Y coordinate of the text anchor point.

public double Y { get; set; }

Property Value

Double
Y coordinate of text anchor point.

Remarks

The anchor point depends on the vertical text alignment.