Skip to main content
All docs
V25.2
  • IRibbonColorGroup Interface

    Defines the programmatic interface for the DxRibbonColorGroup component.

    Namespace: DevExpress.Blazor.Ribbon

    Assembly: DevExpress.Blazor.v25.2.dll

    NuGet Package: DevExpress.Blazor

    Declaration

    public interface IRibbonColorGroup :
        IRibbonNode

    Remarks

    Use the IRibbonColorGroup interface to read and modify DxRibbonColorGroup component properties at runtime and customize the Ribbon color palette item’s color group’s appearance and behavior.

    Obtain an IRibbonColorGroup instance with the @ref attribute or from Ribbon event arguments.

    <DxRibbon>
        <DxRibbonTab Text="Home">
            <DxRibbonGroup>
                <DxRibbonItem Text="Get Color Group Name"
                              Click="GetColorGroupName" />
            </DxRibbonGroup>
            <DxRibbonGroup>
                <DxRibbonColorPaletteItem @bind-Value="color">
                    <DxRibbonColorGroup Header="Universal"
                                        Colors="@DxColorPalettePresets.GetPalette(ColorPalettePresetType.Universal)"
                                        @ref="colorGroupReference" />
                </DxRibbonColorPaletteItem>
            </DxRibbonGroup>
        </DxRibbonTab>
    </DxRibbon>
    
    <p><b>First color group:</b> @colorGroupName</p>
    
    @code {
        string color = "";
        string colorGroupName = "";
        IRibbonColorGroup colorGroupReference;
    
        void GetColorGroupName(RibbonItemClickEventArgs e) {
            colorGroupName = colorGroupReference.Header;
        }
    }
    
    See Also