Class CharacterProperties
Manages character-level formatting (font, size, color, underline, shading) for inline text. Apply to Run elements or character styles to control text appearance with support for theme-aware colors and fonts.
Inherited Members
Namespace: Telerik.Windows.Documents.Flow.Model.Styles
Assembly: Telerik.Windows.Documents.Flow.dll
Syntax
public sealed class CharacterProperties : DocumentElementPropertiesBase, IElementWithStyle, IPropertiesWithShading
Properties
BackgroundColor
Gets or sets the solid background color behind text, which combines with shading patterns when both are applied.
Declaration
public IStyleProperty<ThemableColor> BackgroundColor { get; }
Property Value
|
IStyleProperty<ThemableColor>
The color of the background. |
Implements
BaselineAlignment
Gets or sets the vertical alignment of text relative to the baseline, controlling superscript and subscript positioning.
Declaration
public IStyleProperty<BaselineAlignment? > BaselineAlignment { get; }
Property Value
|
IStyleProperty<System.Nullable<BaselineAlignment>>
The default value is |
FlowDirection
Gets or sets the text flow direction, controlling whether text reads left-to-right or right-to-left for multilingual document support.
Declaration
public IStyleProperty<FlowDirection? > FlowDirection { get; }
Property Value
|
IStyleProperty<System.Nullable<FlowDirection>>
The default value is |
FontFamily
Gets or sets the font family applied to text, supporting both explicit font names and theme-aware font references that adapt to the document's theme.
Declaration
public IStyleProperty<ThemableFontFamily> FontFamily { get; }
Property Value
|
IStyleProperty<ThemableFontFamily>
The font family. |
FontSize
Gets or sets the font size in device-independent pixels (1/96 inch), controlling text height in the rendered document.
Declaration
public IStyleProperty<double? > FontSize { get; }
Property Value
|
IStyleProperty<System.Nullable<System.Double>>
The size of the font. |
FontStyle
Gets or sets the font style (normal or italic) applied to text, determining the slant or posture of characters.
Declaration
public IStyleProperty<FontStyle? > FontStyle { get; }
Property Value
|
IStyleProperty<System.Nullable<System.Windows.FontStyle>>
The default value is |
FontWeight
Gets or sets the font weight (boldness) applied to text, controlling the thickness of character strokes.
Declaration
public IStyleProperty<FontWeight? > FontWeight { get; }
Property Value
|
IStyleProperty<System.Nullable<System.Windows.FontWeight>>
The default value is |
ForegroundColor
Gets or sets the foreground (text) color, supporting both explicit color values and theme-aware colors that adapt to the document's color scheme.
Declaration
public IStyleProperty<ThemableColor> ForegroundColor { get; }
Property Value
|
IStyleProperty<ThemableColor>
The default value is |
HighlightColor
Gets or sets the highlight color applied behind text, simulating a text marker or highlighter pen effect.
Declaration
public IStyleProperty<Color? > HighlightColor { get; }
Property Value
|
IStyleProperty<System.Nullable<System.Windows.Media.Color>>
The default value is |
ShadingPattern
Gets or sets the pattern style used to combine the shading pattern color with the background color, enabling effects like diagonal stripes or dots.
Declaration
public IStyleProperty<ShadingPattern? > ShadingPattern { get; }
Property Value
|
IStyleProperty<System.Nullable<ShadingPattern>>
The default value is |
Implements
ShadingPatternColor
Gets or sets the foreground color for shading patterns, which is layered over the background color according to the specified pattern style.
Declaration
public IStyleProperty<ThemableColor> ShadingPatternColor { get; }
Property Value
|
IStyleProperty<ThemableColor>
The color of the pattern. |
Implements
Strikethrough
Gets or sets whether a horizontal line is drawn through the middle of the text, indicating deletion or emphasis.
Declaration
public IStyleProperty<bool? > Strikethrough { get; }
Property Value
|
IStyleProperty<System.Nullable<System.Boolean>>
The default value is |
UnderlineColor
Gets or sets the color of the underline decoration, which can differ from the text foreground color.
Declaration
public IStyleProperty<ThemableColor> UnderlineColor { get; }
Property Value
|
IStyleProperty<ThemableColor>
The color. |
UnderlinePattern
Gets or sets the underline pattern style (single, double, dashed, wavy, etc.) applied beneath the text.
Declaration
public IStyleProperty<UnderlinePattern? > UnderlinePattern { get; }
Property Value
|
IStyleProperty<System.Nullable<UnderlinePattern>>
The default value is |
Methods
EnumerateStyleProperties()
Enumerates the style properties.
Declaration
protected override IEnumerable<IStyleProperty> EnumerateStyleProperties()
Returns
|
System.Collections.Generic.IEnumerable<IStyleProperty>
The style properties. |
Overrides
GetStylePropertyOverride(IStylePropertyDefinition)
Gets specific style property or null.
Declaration
protected override IStyleProperty GetStylePropertyOverride(IStylePropertyDefinition propertyDefinition)
Parameters
|
IStylePropertyDefinition
propertyDefinition
The property definition. |
Returns
|
IStyleProperty
|
Overrides
Explicit Interface Implementations
IPropertiesWithShading.Document
Gets the document.
Declaration
RadFlowDocument IPropertiesWithShading.Document { get; }
Returns
|
RadFlowDocument
The document. |