Class
Paragraph

Block-level container for inline content with paragraph-specific formatting including alignment, spacing, indentation, borders, and list association.

Definition

Namespace:Telerik.Windows.Documents.Flow.Model

Assembly:Telerik.Windows.Documents.Flow.dll

Syntax:

cs-api-definition
public sealed class Paragraph : BlockBase, IElementWithStyle, IElementWithProperties

Inheritance: objectDocumentElementBaseBlockBaseParagraph

Implements: IElementWithPropertiesIElementWithStyle

Inherited Members BlockBase.BlockContainerDocumentElementBase.EnumerateChildrenOfType<T>()DocumentElementBase.DocumentDocumentElementBase.Parent

Constructors

Paragraph(RadFlowDocument)

Initializes a new instance of the Paragraph class.

Declaration

cs-api-definition
public Paragraph(RadFlowDocument document)

Parameters

document

RadFlowDocument

The document in which the element will be added.

Fields

AllowOverflowPunctuationPropertyDefinition

Defines whether punctuation characters can extend beyond paragraph margins for visual alignment.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<bool?> AllowOverflowPunctuationPropertyDefinition

Field Value

StylePropertyDefinition<bool?>

ApplyEastAsianLineBreakingRulesPropertyDefinition

Defines whether East Asian typography line breaking rules are applied to control line wrapping for CJK text.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<bool?> ApplyEastAsianLineBreakingRulesPropertyDefinition

Field Value

StylePropertyDefinition<bool?>

AutomaticSpacingAfterPropertyDefinition

Defines whether automatic spacing after paragraphs is applied based on document rendering context.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<bool?> AutomaticSpacingAfterPropertyDefinition

Field Value

StylePropertyDefinition<bool?>

AutomaticSpacingBeforePropertyDefinition

Defines whether automatic spacing before paragraphs is applied based on document rendering context.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<bool?> AutomaticSpacingBeforePropertyDefinition

Field Value

StylePropertyDefinition<bool?>

BackgroundColorPropertyDefinition

Defines the background fill color property for paragraph shading.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<ThemableColor> BackgroundColorPropertyDefinition

Field Value

StylePropertyDefinition<ThemableColor>

BordersPropertyDefinition

Defines the border configuration property for paragraphs, controlling line style, color, and thickness on all sides.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<ParagraphBorders> BordersPropertyDefinition

Field Value

StylePropertyDefinition<ParagraphBorders>

ContextualSpacingPropertyDefinition

Defines whether spacing before and after is suppressed when adjacent paragraphs share the same style.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<bool?> ContextualSpacingPropertyDefinition

Field Value

StylePropertyDefinition<bool?>

FirstLineIndentPropertyDefinition

Defines the positive indentation applied to the first line of paragraphs, measured in device-independent pixels.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<double?> FirstLineIndentPropertyDefinition

Field Value

StylePropertyDefinition<double?>

FlowDirectionPropertyDefinition

Defines the text flow direction property, determining left-to-right or right-to-left content rendering.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<FlowDirection?> FlowDirectionPropertyDefinition

Field Value

StylePropertyDefinition<FlowDirection?>

HangingIndentPropertyDefinition

Defines the negative first-line indentation (hanging indent) applied to paragraphs, measured in device-independent pixels.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<double?> HangingIndentPropertyDefinition

Field Value

StylePropertyDefinition<double?>

KeepOnOnePagePropertyDefinition

Defines whether paragraphs should avoid being split across page breaks.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<bool?> KeepOnOnePagePropertyDefinition

Field Value

StylePropertyDefinition<bool?>

KeepWithNextParagraphPropertyDefinition

Defines whether paragraphs should remain on the same page as the following paragraph to prevent separation.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<bool?> KeepWithNextParagraphPropertyDefinition

Field Value

StylePropertyDefinition<bool?>

LeftIndentPropertyDefinition

Defines the left margin indentation for paragraphs, measured in device-independent pixels.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<double?> LeftIndentPropertyDefinition

Field Value

StylePropertyDefinition<double?>

LineSpacingPropertyDefinition

Defines the line spacing value property, interpreted based on the line spacing type setting.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<double?> LineSpacingPropertyDefinition

Field Value

StylePropertyDefinition<double?>

LineSpacingTypePropertyDefinition

Defines how the line spacing value is interpreted (exact, at least, or multiple of line height).

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<HeightType?> LineSpacingTypePropertyDefinition

Field Value

StylePropertyDefinition<HeightType?>

ListIdPropertyDefinition

Defines the list identifier property that associates paragraphs with a specific list definition.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<int?> ListIdPropertyDefinition

Field Value

StylePropertyDefinition<int?>

ListLevelPropertyDefinition

Defines the list level property (0-8) that determines indentation and numbering format within a list.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<int?> ListLevelPropertyDefinition

Field Value

StylePropertyDefinition<int?>

MirrorIndentsPropertyDefinition

Defines whether left and right indents are swapped on odd pages to support facing-page layouts.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<bool?> MirrorIndentsPropertyDefinition

Field Value

StylePropertyDefinition<bool?>

OutlineLevelPropertyDefinition

Defines the outline level property that determines paragraph hierarchy in table of contents and document structure.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<OutlineLevel?> OutlineLevelPropertyDefinition

Field Value

StylePropertyDefinition<OutlineLevel?>

PageBreakBeforePropertyDefinition

Defines whether a page break is inserted before paragraphs, forcing them to start on a new page.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<bool?> PageBreakBeforePropertyDefinition

Field Value

StylePropertyDefinition<bool?>

RightIndentPropertyDefinition

Defines the right margin indentation for paragraphs, measured in device-independent pixels.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<double?> RightIndentPropertyDefinition

Field Value

StylePropertyDefinition<double?>

ShadingPatternColorPropertyDefinition

Defines the foreground pattern color property for paragraph shading when a pattern is applied.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<ThemableColor> ShadingPatternColorPropertyDefinition

Field Value

StylePropertyDefinition<ThemableColor>

ShadingPatternPropertyDefinition

Defines the fill pattern style property for paragraph shading (e.g., solid, diagonal stripes, dots).

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<ShadingPattern?> ShadingPatternPropertyDefinition

Field Value

StylePropertyDefinition<ShadingPattern?>

SpacingAfterPropertyDefinition

Defines the spacing after paragraph property, measured in device-independent pixels.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<double?> SpacingAfterPropertyDefinition

Field Value

StylePropertyDefinition<double?>

SpacingBeforePropertyDefinition

Defines the spacing before paragraph property, measured in device-independent pixels.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<double?> SpacingBeforePropertyDefinition

Field Value

StylePropertyDefinition<double?>

TabStopsPropertyDefinition

Defines the collection of custom tab stop positions and alignments for paragraphs.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<TabStopCollection> TabStopsPropertyDefinition

Field Value

StylePropertyDefinition<TabStopCollection>

TextAlignmentPropertyDefinition

Defines the horizontal text alignment property for paragraphs.

Declaration

cs-api-definition
public static readonly StylePropertyDefinition<Alignment?> TextAlignmentPropertyDefinition

Field Value

StylePropertyDefinition<Alignment?>

Properties

AllowOverflowPunctuation

Gets or sets whether punctuation characters can extend beyond paragraph margins for visual alignment; defaults to true.

Declaration

cs-api-definition
public bool AllowOverflowPunctuation { get; set; }

Property Value

bool

The default is true.

ApplyEastAsianLineBreakingRules

Gets or sets whether East Asian typography line breaking rules are applied to control line wrapping behavior for CJK text; defaults to true.

Declaration

cs-api-definition
public bool ApplyEastAsianLineBreakingRules { get; set; }

Property Value

bool

The default value is true.

Borders

Gets or sets the border configuration for all sides of the paragraph, controlling line style, color, and thickness.

Declaration

cs-api-definition
public ParagraphBorders Borders { get; set; }

Property Value

ParagraphBorders

The borders.

ContextualSpacing

Gets or sets whether spacing before and after is suppressed when adjacent paragraphs share the same paragraph style; defaults to false.

Declaration

cs-api-definition
public bool ContextualSpacing { get; set; }

Property Value

bool

The default value is false.

FlowDirection

Gets or sets the text flow direction for the paragraph, determining whether content flows left-to-right or right-to-left; defaults to LeftToRight.

Declaration

cs-api-definition
public FlowDirection FlowDirection { get; set; }

Property Value

FlowDirection

The default value is LeftToRight

Indentation

Gets the indentation settings for this paragraph, controlling left, right, first-line, and hanging indents.

Declaration

cs-api-definition
public ParagraphIndentation Indentation { get; }

Property Value

ParagraphIndentation

The indentation.

Inlines

Gets the collection of inline elements (runs, images, fields) contained within this paragraph.

Declaration

cs-api-definition
public InlineCollection Inlines { get; }

Property Value

InlineCollection

The inlines.

KeepOnOnePage

Gets or sets whether the paragraph should not be split across page breaks in page view mode; defaults to false.

Declaration

cs-api-definition
public bool KeepOnOnePage { get; set; }

Property Value

bool

The default value is false

KeepWithNextParagraph

Gets or sets whether this paragraph should remain on the same page as the following paragraph to prevent separation by page breaks; defaults to false.

Declaration

cs-api-definition
public bool KeepWithNextParagraph { get; set; }

Property Value

bool

The default value is false

ListId

Gets or sets the identifier of the list definition this paragraph belongs to, enabling list formatting.

Declaration

cs-api-definition
public int ListId { get; set; }

Property Value

int

The list id.

ListLevel

Gets or sets the list level (0-8) that determines indentation and numbering format within the associated list; defaults to -1 (no list).

Declaration

cs-api-definition
public int ListLevel { get; set; }

Property Value

int

The default value is -1 - list style is not referenced.

MirrorIndents

Gets or sets whether left and right indents are swapped on odd pages to support mirrored margins in facing-page layouts; defaults to false.

Declaration

cs-api-definition
public bool MirrorIndents { get; set; }

Property Value

bool

The default value is false.

OutlineLevel

Gets or sets the outline level that determines this paragraph's hierarchy in table of contents and document structure; defaults to Level9 (no outline level).

Declaration

cs-api-definition
public OutlineLevel OutlineLevel { get; set; }

Property Value

OutlineLevel

The default value is Level9 - no level.

PageBreakBefore

Gets or sets whether a page break is inserted before this paragraph in page view mode, forcing the paragraph to start on a new page; defaults to false.

Declaration

cs-api-definition
public bool PageBreakBefore { get; set; }

Property Value

bool

The default value is false

Properties

Gets the formatting properties container for this paragraph, providing access to alignment, spacing, indentation, borders, and other paragraph-level settings.

Declaration

cs-api-definition
public ParagraphProperties Properties { get; }

Property Value

ParagraphProperties

The properties.

Shading

Gets the background shading settings applied to the paragraph's area, including fill color and pattern.

Declaration

cs-api-definition
public Shading Shading { get; }

Property Value

Shading

The shading.

Spacing

Gets the spacing settings for this paragraph, controlling space before, after, and line spacing values.

Declaration

cs-api-definition
public ParagraphSpacing Spacing { get; }

Property Value

ParagraphSpacing

The paragraph spacing.

StyleId

Gets or sets the identifier of the paragraph style applied to this paragraph, affecting formatting through style inheritance.

Declaration

cs-api-definition
public string StyleId { get; set; }

Property Value

string

The style id.

Implements IElementWithStyle.StyleId

TabStops

Gets or sets the collection of custom tab stop positions and alignments for this paragraph.

Declaration

cs-api-definition
public TabStopCollection TabStops { get; set; }

Property Value

TabStopCollection

The tab stops.

TextAlignment

Gets or sets the horizontal alignment of text within the paragraph; defaults to Left.

Declaration

cs-api-definition
public Alignment TextAlignment { get; set; }

Property Value

Alignment

The default value is Left

Methods

Clone()

Creates a deep copy of this paragraph with all inlines and formatting, associated to the current document.

Declaration

cs-api-definition
public Paragraph Clone()

Returns

Paragraph

The cloned element.

Clone(RadFlowDocument)

Creates a deep copy of this paragraph with all inlines and formatting, associated to the specified document.

Declaration

cs-api-definition
public Paragraph Clone(RadFlowDocument document)

Parameters

document

RadFlowDocument

The document to which the cloned element should be associated.

Returns

Paragraph

The cloned element.