Base class for toggle-style format toolbar buttons (Bold, Italic, Underline, Strikethrough, TextWrap). Subclasses only need to override Format) and Boolean).
IComponent
IHandleEvent
IHandleAfterRender
ComponentBase.BuildRenderTree
ComponentBase.OnInitialized
ComponentBase.OnInitializedAsync
ComponentBase.OnParametersSetAsync
ComponentBase.StateHasChanged
ComponentBase.ShouldRender
ComponentBase.OnAfterRender
ComponentBase.OnAfterRenderAsync
ComponentBase.InvokeAsync
ComponentBase.DispatchExceptionAsync
ComponentBase.SetParametersAsync
ComponentBase.RendererInfo
ComponentBase.Assets
ComponentBase.AssignedRenderMode
Namespace: Radzen.Blazor
Assembly: Radzen.Blazor.dll
public abstract class RadzenSpreadsheetFormatToggleToolBase : ComponentBase, IComponent, IHandleEvent, IHandleAfterRenderInitializes a new instance of the RadzenSpreadsheetFormatToggleToolBase class.
protected RadzenSpreadsheetFormatToggleToolBase()Gets whether the tool should be disabled.
protected bool IsDisabled { get; }
| Type | Description |
|---|---|
| bool | Gets whether the tool should be disabled. |
Derived state: whether the selected cell's format has this property toggled on.
protected bool IsToggled { get; }
| Type | Description |
|---|---|
| bool | Derived state: whether the selected cell's format has this property toggled on. |
The host spreadsheet, cascaded from RadzenSpreadsheet.
public ISpreadsheet Spreadsheet { get; set; }
| Type | Description |
|---|---|
| ISpreadsheet | The host spreadsheet, cascaded from RadzenSpreadsheet. |
The active worksheet, cascaded from the host RadzenSpreadsheet.
public Documents.Spreadsheet.Worksheet Worksheet { get; set; }
| Type | Description |
|---|---|
| Documents.Spreadsheet.Worksheet | The active worksheet, cascaded from the host RadzenSpreadsheet. |
Reads the boolean property from the cell's format (e.g. format.Bold).
protected abstract bool GetValue(Documents.Spreadsheet.Format format)
| Type | Name | Description |
|---|---|---|
| Documents.Spreadsheet.Format | format |
| Type | Description |
|---|---|
| bool |
Dispatches a FormatCommand to set the toggle to value. Used as the ValueChanged callback for the underlying toggle button.
protected Task OnToggledChangedAsync(bool value)
| Type | Name | Description |
|---|---|---|
| bool | value |
| Type | Description |
|---|---|
| Task |
Returns a new format with the boolean property set (e.g. format.WithBold(value)).
protected abstract Documents.Spreadsheet.Format WithValue(Documents.Spreadsheet.Format format, bool value)
| Type | Name | Description |
|---|---|---|
| Documents.Spreadsheet.Format | format | |
| bool | value |
| Type | Description |
|---|---|
| Documents.Spreadsheet.Format |