Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

DxRichEdit.CheckSpelling Property

Specifies whether to check spelling in the Rich Text Editor.

Namespace: DevExpress.Blazor.RichEdit

Assembly: DevExpress.Blazor.RichEdit.v24.2.dll

NuGet Package: DevExpress.Blazor.RichEdit

#Declaration

C#
[DefaultValue(false)]
[Parameter]
public bool CheckSpelling { get; set; }

#Property Value

Type Default Description
Boolean false

true to check spelling; otherwise, false.

#Remarks

The Rich Text Editor allows you to use a built-in or custom service to check spelling. Add a spell check service and set the CheckSpelling property to true to enable the spell check feature. The following code snippet adds a Check Spelling check button that allows users to enable/disable this feature at runtime:

Razor
<DxRichEdit @ref="@richEdit" CheckSpelling="check" DocumentCulture="en-US" CustomizeRibbon=OnCustomizeRibbon/>

@code {
    DxRichEdit richEdit;
    bool check = true;

    void OnCustomizeRibbon(IRibbon ribbon) {
        IRibbonTab viewTab = ribbon.Tabs[RichEditRibbonTabNames.View];
        IBarGroup spellCheckGroup = viewTab.Groups.AddCustomGroup(0);
        IBarCheckableButton spellCheckButton = spellCheckGroup.Items.AddCustomCheckButton(0, "Check Spelling",
            async () =>  {
                check = !check;
                StateHasChanged();
            },
            () => check
        );
    }
}

See Also