Skip to main content

InsertTableRowAction Class

Definition

Assembly:Avalonia.Controls.RichTextEditor
Package:Avalonia.Controls.RichTextEditor

Action for inserting a new row before or after the current row in a Avalonia.Controls.Documents.Table.

public class InsertTableRowAction

Inheritance: object -> EditorAction -> InsertTableRowAction

Remarks

Two static instances (Avalonia.Controls.Documents.Primitives.Actions.InsertTableRowAction.Before and Avalonia.Controls.Documents.Primitives.Actions.InsertTableRowAction.After) are provided for convenience and registered in Avalonia.Controls.Documents.Primitives.Actions.EditorActions.

Avalonia.Controls.Documents.Primitives.Actions.InsertTableRowAction.CanExecute(Avalonia.Controls.Documents.Primitives.ITextEditorHost) returns true only when the caret is inside a Avalonia.Controls.Documents.TableRow. The new row has the same number of cells as the reference row, each containing an empty paragraph.

Methods

NameDescription
CanExecuteNo summary available.
ExecuteNo summary available.
ExecuteAsyncExecutes the action asynchronously. Inherited from EditorAction.
GetStateGets the current state of the action. Inherited from EditorAction.

CanExecute Method

public bool CanExecute(Avalonia.Controls.Documents.Primitives.ITextEditorHost host)

Parameters

host Avalonia.Controls.Documents.Primitives.ITextEditorHost

Returns

bool

Execute Method

public void Execute(Avalonia.Controls.Documents.Primitives.ITextEditorHost host)

Parameters

host Avalonia.Controls.Documents.Primitives.ITextEditorHost

Properties

NameDescription
DisplayNameNo summary available.
IdNo summary available.
GestureGets the optional keyboard gesture for this action. Inherited from EditorAction.

DisplayName Property

public string DisplayName { get; set; }

Id Property

public string Id { get; set; }

Fields

NameDescription
AfterSingleton instance that inserts a row after the current row.
BeforeSingleton instance that inserts a row before the current row.

After Field

Singleton instance that inserts a row after the current row.

public Avalonia.Controls.Documents.Primitives.Actions.InsertTableRowAction After

Before Field

Singleton instance that inserts a row before the current row.

public Avalonia.Controls.Documents.Primitives.Actions.InsertTableRowAction Before