Carries the document, owner, and optional existing style data used to create or edit styles in the formatting dialog. It also supplies the default style factories and persistence operations used by that dialog.
Definition
Namespace:Telerik.WinForms.Documents.UI.Extensibility
Assembly:Telerik.WinControls.RichTextEditor.dll
Syntax:
public class StyleFormattingPropertiesDialogContext
Inheritance: objectStyleFormattingPropertiesDialogContext
Constructors
Initializes a new instance of the StyleFormattingPropertiesDialogContext class. Use it for editing of list style.
public StyleFormattingPropertiesDialogContext(string dialogTitle, ListStyle realListStyle, RadRichTextBox owner)
The dialog title.
realListStyleListStyleThe real list style.
ownerRadRichTextBoxThe owner.
Initializes a new instance of the StyleFormattingPropertiesDialogContext class. Use it for creation of new style.
public StyleFormattingPropertiesDialogContext(string dialogTitle, RadRichTextBox owner)
The dialog title.
ownerRadRichTextBoxThe owner.
Initializes a new instance of the StyleFormattingPropertiesDialogContext class. Use it for editing of style definition.
public StyleFormattingPropertiesDialogContext(string dialogTitle, StyleDefinition realStyleDefinition, RadRichTextBox owner)
The dialog title.
realStyleDefinitionStyleDefinitionThe real style definition.
ownerRadRichTextBoxThe owner.
Initializes a new instance of the StyleFormattingPropertiesDialogContext class. Use it for creation of new style with specified type.
public StyleFormattingPropertiesDialogContext(string dialogTitle, StyleType styleType, RadRichTextBox owner)
The dialog title.
styleTypeStyleTypeType of the style.
ownerRadRichTextBoxThe owner.
Properties
Gets or sets the title displayed by the style-formatting dialog.
public string DialogTitle { get; }
Gets the document owned by Owner.
public RadDocument Document { get; }
Gets or sets the rich text box whose document and editor state are used by the dialog.
public RadRichTextBox Owner { get; }
Gets or sets the existing list style being edited, when applicable.
public ListStyle RealListStyle { get; }
Gets or sets the existing style definition being edited, when applicable.
public StyleDefinition RealStyleDefinition { get; }
Gets the owner's style repository.
public StyleCollection StyleCollection { get; }
Methods
Adds a non-null list style to the owner's document.
public virtual void AddListStyle(ListStyle listStyle)
The list style to add.
Adds a copy of a named style definition to the owner's repository and activates it in the editor.
If the supplied style has a linked style, this method also renames that linked style by appending Char to the main style name.
public virtual void AddStyleDefinition(StyleDefinition style)
The style definition to copy into the repository.
Applies the supplied list-style values to the existing list style with the same ID, then refreshes document presentation and layout.
public virtual void EditListStyle(ListStyle listStyle)
The edited list-style values.
Copies the edited style properties into the existing definition and refreshes document presentation and layout.
public virtual void EditStyleDefinition(StyleDefinition style)
The edited style values to apply to RealStyleDefinition.
Creates a custom character style with the next available name.
public virtual StyleDefinition GetCharacterStyle()
A new character style that has not yet been added to the document.
Creates a paragraph style with an associated character style named by appending Char.
public virtual StyleDefinition GetLinkedStyle()
A new linked-style definition that has not yet been added to the document.
Creates a list style from the default parenthesized numbering pattern and assigns the next available style link.
public virtual ListStyle GetListStyle()
A new list style that has not yet been added to the document.
Creates a custom paragraph style based on the document's Normal style.
public virtual StyleDefinition GetParagraphStyle()
A new paragraph style that has not yet been added to the document.
Gets the owner's action for displaying the symbol-insertion dialog.
public virtual Action<Action<char, FontFamily>, FontFamily, RadRichTextBox> GetShowInsertSymbolDialogAction()
Action<Action<char, FontFamily>, FontFamily, RadRichTextBox>
A delegate that displays the owner's symbol dialog.
Creates a default style definition for the requested category. Character, paragraph, and table styles receive category-specific defaults; other types use the generic defaults.
public virtual StyleDefinition GetStyle(StyleType styleType)
The model style category to create.
Returns:A new, named style definition that has not yet been added to the document.
Creates a custom table style based on the default normal table style with priority 100 and single auto line spacing.
public virtual StyleDefinition GetTableStyle()
A new table style that has not yet been added to the document.