GemBox.Presentation
  • Overview
  • Examples
  • Free version
  • Support
  • Pricelist

    Show / Hide Table of Contents

    TextParagraphFormat Class

    Namespace:
    GemBox.Presentation
    Assembly:
    GemBox.Presentation.dll

    Represents a set of formatting properties that can be applied to a TextParagraph.

    • C#
    • VB.NET
    public sealed class TextParagraphFormat
    Public NotInheritable Class TextParagraphFormat
    Inheritance:
    System.Object
    TextParagraphFormat

    Properties

    Alignment

    Gets or sets the alignment that is to be applied to the paragraph.

    Default value is Left.

    • C#
    • VB.NET
    public HorizontalAlignment Alignment { get; set; }
    Public Property Alignment As HorizontalAlignment
    Property Value
    HorizontalAlignment

    The alignment that is to be applied to the paragraph.

    Character

    Gets or sets the default character formatting options for all TextElements within a containing TextParagraph.

    These options are used when child TextElement doesn't have a specific character formatting options from Format specified.

    • C#
    • VB.NET
    public TextCharacterFormat Character { get; }
    Public ReadOnly Property Character As TextCharacterFormat
    Property Value
    TextCharacterFormat

    The default character formatting options for all TextElements within a containing TextParagraph.

    Remarks

    This property always returns a new instance of a TextCharacterFormat that points to data associated with this paragraph formatting. This reduces memory footprint since simpler internal structures can be used to hold the data and execution time increase is negligible since Garbage Collector has a very good performance for a short-lived (Generation 0) objects.

    IndentationBeforeText

    Gets or sets the indentation before text of the TextParagraph.

    This is specified in addition to the InternalMarginLeft and applies only to this TextParagraph. That is the InternalMarginLeft and the IndentationBeforeText are additive with respect to the text position.

    Default value is 0.

    • C#
    • VB.NET
    public Length IndentationBeforeText { get; set; }
    Public Property IndentationBeforeText As Length
    Property Value
    Length

    The indentation before text of the TextParagraph.

    Exceptions
    System.ArgumentOutOfRangeException

    Value is not between 0 and 142.24 cm.

    IndentationSpecial

    Gets or sets the special indentation that is applied to the first line of text in the TextParagraph.

    Positive value specifies First line indentation, negative values specifies Hanging indentation and value of zero is considered to be at the same location as IndentationBeforeText property.

    Default value is 0.

    • C#
    • VB.NET
    public Length IndentationSpecial { get; set; }
    Public Property IndentationSpecial As Length
    Property Value
    Length

    The special indentation that is applied to the first line of text in the TextParagraph.

    Exceptions
    System.ArgumentOutOfRangeException

    Value is not between -142.24 cm and 142.24 cm.

    List

    Gets the paragraph's list (bulleted or numbered) formatting options.

    • C#
    • VB.NET
    public TextListFormat List { get; }
    Public ReadOnly Property List As TextListFormat
    Property Value
    TextListFormat

    The paragraph's list (bulleted or numbered) formatting options.

    RightToLeft

    When true, this is a right-to-left paragraph.

    • C#
    • VB.NET
    public bool RightToLeft { get; set; }
    Public Property RightToLeft As Boolean
    Property Value
    System.Boolean

    true if this is right-to-left paragraph; otherwise, false.

    SpacingAfter

    Gets or sets the amount of vertical white space that is present after a TextParagraph. This space is specified in either percentage or absolute value via TextSpacing structure.

    Default value is equal to None.

    Percentage based value is currently not supported in PDF, XPS, and image formats and 0 point value is exported instead.

    • C#
    • VB.NET
    public TextSpacing SpacingAfter { get; set; }
    Public Property SpacingAfter As TextSpacing
    Property Value
    TextSpacing

    The amount of vertical white space that is present after a TextParagraph.

    SpacingBefore

    Gets or sets the amount of vertical white space that is present before a TextParagraph. This space is specified in either percentage or absolute value via TextSpacing structure.

    Default value is equal to None.

    Percentage based value is currently not supported in PDF, XPS, and image formats and 0 point value is exported instead.

    • C#
    • VB.NET
    public TextSpacing SpacingBefore { get; set; }
    Public Property SpacingBefore As TextSpacing
    Property Value
    TextSpacing

    The amount of vertical white space that is present before a TextParagraph.

    SpacingLine

    Gets or sets the vertical line spacing that is to be used within a TextParagraph. This can be specified in two different ways, percentage spacing and absolute spacing via TextSpacing structure.

    Default value is equal to Single.

    • C#
    • VB.NET
    public TextSpacing SpacingLine { get; set; }
    Public Property SpacingLine As TextSpacing
    Property Value
    TextSpacing

    The vertical line spacing that is to be used within a TextParagraph.

    Tabs

    Gets all tab stops that are to be used within a TextParagraph.

    Default value is empty TabStopCollection.

    • C#
    • VB.NET
    public TabStopCollection Tabs { get; }
    Public ReadOnly Property Tabs As TabStopCollection
    Property Value
    TabStopCollection

    All tab stops that are to be used within a TextParagraph.

    Remarks

    These tabs should be used when describing any custom tab stops within the document. If these are not specified then the DefaultSize should be used.

    Examples

    Paragraph Formatting Example
    Back to top

    Facebook • Twitter • LinkedIn

    © GemBox Ltd. — All rights reserved.