New to Telerik UI for WinFormsStart a free 30-day trial

Represents a command that can change the state of the format painter.

Definition

Constructors

Initializes a new instance of the ChangeFormatPainterStateCommand class.

C#
public ChangeFormatPainterStateCommand(RadRichTextBox editor)
Parameters:editorRadRichTextBox

The RadRichTextBox associated with the command.

Properties

Gets a value indicating whether the behavior of the command can be executed in a protected document.

C#
protected override CanExecuteBehaviorInProtectedDocument CanExecuteBehaviorInProtectedDocument { get; }

Overrides: RichTextBoxCommandBase.CanExecuteBehaviorInProtectedDocument

Gets a value indicating whether this command can be executed when RadRichTextBox is read-only. The default implementation returns true.

C#
protected override bool CanExecuteInReadOnlyMode { get; }
Property Value:

true if this command preserves document's content; otherwise, false.

Overrides: RichTextBoxCommandBase.CanExecuteInReadOnlyMode

Gets a value indicating whether this command can be executed when editing context is read-only. The default implementation returns true.

C#
protected override bool CanExecuteInReadOnlyRange { get; }

Overrides: RichTextBoxCommandBase.CanExecuteInReadOnlyRange

Methods

Performs the execute action specific to the command.

C#
protected override void ExecuteOverride(object parameter)
Parameters:parameterobject

The command parameter.

Overrides: RichTextBoxCommandBase.ExecuteOverride(object)

Called when the state of the format painter of the RadRichTextBox has changed.

C#
protected virtual void OnStateChanged()

Events

Occurs when the state of the format painter of the RadRichTextBox has changed.

C#
public event EventHandler<FormatPainterStateChangedEventArgs> StateChanged