ClassParagraph
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:
public sealed class Paragraph : BlockBase, IElementWithStyle, IElementWithProperties
Inheritance: objectDocumentElementBaseBlockBaseParagraph
Implements:
Inherited Members
Constructors
Paragraph(RadFlowDocument)
Initializes a new instance of the Paragraph class.
Declaration
public Paragraph(RadFlowDocument document)
Parameters
document
The document in which the element will be added.
Fields
AllowOverflowPunctuationPropertyDefinition
Defines whether punctuation characters can extend beyond paragraph margins for visual alignment.
Declaration
public static readonly StylePropertyDefinition<bool?> AllowOverflowPunctuationPropertyDefinition
Field Value
ApplyEastAsianLineBreakingRulesPropertyDefinition
Defines whether East Asian typography line breaking rules are applied to control line wrapping for CJK text.
Declaration
public static readonly StylePropertyDefinition<bool?> ApplyEastAsianLineBreakingRulesPropertyDefinition
Field Value
AutomaticSpacingAfterPropertyDefinition
Defines whether automatic spacing after paragraphs is applied based on document rendering context.
Declaration
public static readonly StylePropertyDefinition<bool?> AutomaticSpacingAfterPropertyDefinition
Field Value
AutomaticSpacingBeforePropertyDefinition
Defines whether automatic spacing before paragraphs is applied based on document rendering context.
Declaration
public static readonly StylePropertyDefinition<bool?> AutomaticSpacingBeforePropertyDefinition
Field Value
BackgroundColorPropertyDefinition
Defines the background fill color property for paragraph shading.
Declaration
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
public static readonly StylePropertyDefinition<ParagraphBorders> BordersPropertyDefinition
Field Value
ContextualSpacingPropertyDefinition
Defines whether spacing before and after is suppressed when adjacent paragraphs share the same style.
Declaration
public static readonly StylePropertyDefinition<bool?> ContextualSpacingPropertyDefinition
Field Value
FirstLineIndentPropertyDefinition
Defines the positive indentation applied to the first line of paragraphs, measured in device-independent pixels.
Declaration
public static readonly StylePropertyDefinition<double?> FirstLineIndentPropertyDefinition
Field Value
FlowDirectionPropertyDefinition
Defines the text flow direction property, determining left-to-right or right-to-left content rendering.
Declaration
public static readonly StylePropertyDefinition<FlowDirection?> FlowDirectionPropertyDefinition
Field Value
HangingIndentPropertyDefinition
Defines the negative first-line indentation (hanging indent) applied to paragraphs, measured in device-independent pixels.
Declaration
public static readonly StylePropertyDefinition<double?> HangingIndentPropertyDefinition
Field Value
KeepOnOnePagePropertyDefinition
Defines whether paragraphs should avoid being split across page breaks.
Declaration
public static readonly StylePropertyDefinition<bool?> KeepOnOnePagePropertyDefinition
Field Value
KeepWithNextParagraphPropertyDefinition
Defines whether paragraphs should remain on the same page as the following paragraph to prevent separation.
Declaration
public static readonly StylePropertyDefinition<bool?> KeepWithNextParagraphPropertyDefinition
Field Value
LeftIndentPropertyDefinition
Defines the left margin indentation for paragraphs, measured in device-independent pixels.
Declaration
public static readonly StylePropertyDefinition<double?> LeftIndentPropertyDefinition
Field Value
LineSpacingPropertyDefinition
Defines the line spacing value property, interpreted based on the line spacing type setting.
Declaration
public static readonly StylePropertyDefinition<double?> LineSpacingPropertyDefinition
Field Value
LineSpacingTypePropertyDefinition
Defines how the line spacing value is interpreted (exact, at least, or multiple of line height).
Declaration
public static readonly StylePropertyDefinition<HeightType?> LineSpacingTypePropertyDefinition
Field Value
ListIdPropertyDefinition
Defines the list identifier property that associates paragraphs with a specific list definition.
Declaration
public static readonly StylePropertyDefinition<int?> ListIdPropertyDefinition
Field Value
ListLevelPropertyDefinition
Defines the list level property (0-8) that determines indentation and numbering format within a list.
Declaration
public static readonly StylePropertyDefinition<int?> ListLevelPropertyDefinition
Field Value
MirrorIndentsPropertyDefinition
Defines whether left and right indents are swapped on odd pages to support facing-page layouts.
Declaration
public static readonly StylePropertyDefinition<bool?> MirrorIndentsPropertyDefinition
Field Value
OutlineLevelPropertyDefinition
Defines the outline level property that determines paragraph hierarchy in table of contents and document structure.
Declaration
public static readonly StylePropertyDefinition<OutlineLevel?> OutlineLevelPropertyDefinition
Field Value
PageBreakBeforePropertyDefinition
Defines whether a page break is inserted before paragraphs, forcing them to start on a new page.
Declaration
public static readonly StylePropertyDefinition<bool?> PageBreakBeforePropertyDefinition
Field Value
RightIndentPropertyDefinition
Defines the right margin indentation for paragraphs, measured in device-independent pixels.
Declaration
public static readonly StylePropertyDefinition<double?> RightIndentPropertyDefinition
Field Value
ShadingPatternColorPropertyDefinition
Defines the foreground pattern color property for paragraph shading when a pattern is applied.
Declaration
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
public static readonly StylePropertyDefinition<ShadingPattern?> ShadingPatternPropertyDefinition
Field Value
SpacingAfterPropertyDefinition
Defines the spacing after paragraph property, measured in device-independent pixels.
Declaration
public static readonly StylePropertyDefinition<double?> SpacingAfterPropertyDefinition
Field Value
SpacingBeforePropertyDefinition
Defines the spacing before paragraph property, measured in device-independent pixels.
Declaration
public static readonly StylePropertyDefinition<double?> SpacingBeforePropertyDefinition
Field Value
TabStopsPropertyDefinition
Defines the collection of custom tab stop positions and alignments for paragraphs.
Declaration
public static readonly StylePropertyDefinition<TabStopCollection> TabStopsPropertyDefinition
Field Value
TextAlignmentPropertyDefinition
Defines the horizontal text alignment property for paragraphs.
Declaration
public static readonly StylePropertyDefinition<Alignment?> TextAlignmentPropertyDefinition
Field Value
Properties
AllowOverflowPunctuation
Gets or sets whether punctuation characters can extend beyond paragraph margins for visual alignment; defaults to true.
Declaration
public bool AllowOverflowPunctuation { get; set; }
Property Value
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
public bool ApplyEastAsianLineBreakingRules { get; set; }
Property Value
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
public ParagraphBorders Borders { get; set; }
Property Value
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
public bool ContextualSpacing { get; set; }
Property Value
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
public FlowDirection FlowDirection { get; set; }
Property Value
The default value is LeftToRight
Indentation
Gets the indentation settings for this paragraph, controlling left, right, first-line, and hanging indents.
Declaration
public ParagraphIndentation Indentation { get; }
Property Value
The indentation.
Inlines
Gets the collection of inline elements (runs, images, fields) contained within this paragraph.
Declaration
public InlineCollection Inlines { get; }
Property Value
The inlines.
KeepOnOnePage
Gets or sets whether the paragraph should not be split across page breaks in page view mode; defaults to false.
Declaration
public bool KeepOnOnePage { get; set; }
Property Value
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
public bool KeepWithNextParagraph { get; set; }
Property Value
The default value is false
ListId
Gets or sets the identifier of the list definition this paragraph belongs to, enabling list formatting.
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
public int ListLevel { get; set; }
Property Value
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
public bool MirrorIndents { get; set; }
Property Value
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
public OutlineLevel OutlineLevel { get; set; }
Property Value
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
public bool PageBreakBefore { get; set; }
Property Value
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
public ParagraphProperties Properties { get; }
Property Value
The properties.
Shading
Gets the background shading settings applied to the paragraph's area, including fill color and pattern.
Spacing
Gets the spacing settings for this paragraph, controlling space before, after, and line spacing values.
Declaration
public ParagraphSpacing Spacing { get; }
Property Value
The paragraph spacing.
StyleId
Gets or sets the identifier of the paragraph style applied to this paragraph, affecting formatting through style inheritance.
Declaration
public string StyleId { get; set; }
Property Value
The style id.
Implements
TabStops
Gets or sets the collection of custom tab stop positions and alignments for this paragraph.
Declaration
public TabStopCollection TabStops { get; set; }
Property Value
The tab stops.
TextAlignment
Gets or sets the horizontal alignment of text within the paragraph; defaults to Left.
Declaration
public Alignment TextAlignment { get; set; }
Property Value
The default value is Left
Methods
Clone()
Creates a deep copy of this paragraph with all inlines and formatting, associated to the current document.
Clone(RadFlowDocument)
Creates a deep copy of this paragraph with all inlines and formatting, associated to the specified document.
Declaration
public Paragraph Clone(RadFlowDocument document)
Parameters
document
The document to which the cloned element should be associated.
Returns
The cloned element.