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

RichEditBarItemNames.MarginsNormal Property

Gets the Margins Normal item’s name.

Namespace: DevExpress.Blazor.RichEdit

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

NuGet Package: DevExpress.Blazor.RichEdit

#Declaration

C#
public static string MarginsNormal { get; }

#Property Value

Type Description
String

The “MarginsNormal” string.

#Remarks

Use this property to perform the following operations with the Margins Normal item:

The Margins Normal item is a button in the Page Margins Menu. This button allows users to set the top and bottom margins of the selected sections to 2 centimeters, the left margin to 3 centimeters, and the right margin to 1.5 centimeters.

The following code snippet removes the Margins Normal item from the Page Margins Menu:

Razor
<DxRichEdit CustomizeRibbon="onCustomizeRibbon" />

@code {
    void onCustomizeRibbon(IRibbon ribbon) {
        IBarItem pageMarginsMenu = ribbon.Tabs[RichEditRibbonTabNames.PageLayout].Groups[RichEditRibbonGroupNames.PageSetup].Items[RichEditBarItemNames.PageMarginsMenu];
        if (pageMarginsMenu.Type == BarItemTypes.DropDown) {
            IBarDropDown pageMarginsDropDown = (IBarDropDown)pageMarginsMenu;
            pageMarginsDropDown.Items.Remove(RichEditBarItemNames.MarginsModerate);
            pageMarginsDropDown.Items.Remove(RichEditBarItemNames.MarginsNarrow);
            pageMarginsDropDown.Items.Remove(RichEditBarItemNames.MarginsNormal);
            pageMarginsDropDown.Items.Remove(RichEditBarItemNames.MarginsWide);
            pageMarginsDropDown.Items.Remove(RichEditBarItemNames.ShowPageMarginsSetupDialog);
        }
    }
}
See Also