Back to Devexpress

RibbonPageGroup.Margin Property

wpf-devexpress-dot-xpf-dot-ribbon-dot-ribbonpagegroup-7dfa5954.md

latest3.6 KB
Original Source

RibbonPageGroup.Margin Property

Gets or sets the outer indents around the RibbonPageGroup. This is a dependency property.

Namespace : DevExpress.Xpf.Ribbon

Assembly : DevExpress.Xpf.Ribbon.v25.2.dll

NuGet Package : DevExpress.Wpf.Ribbon

Declaration

csharp
public Thickness Margin { get; set; }
vb
Public Property Margin As Thickness

Property Value

TypeDescription
Thickness

A Thickness that represents the outer indents around the RibbonPageGroup.

|

Remarks

The following code sample specifies the RibbonPageGroup‘s Background, Foreground, BorderBrush, BorderThickness CornerRadius, Margin , and Padding properties:

xaml
<dx:ThemedWindow ...
  xmlns:dxr="http://schemas.devexpress.com/winfx/2008/xaml/ribbon" 
  xmlns:dx="http://schemas.devexpress.com/winfx/2008/xaml/core">
  <dxr:RibbonControl>
    <dxr:RibbonDefaultPageCategory>
      <dxr:RibbonPage Caption="Home">
        <dxr:RibbonPageGroup Name="pgFile" Caption="File" ShowCaptionButton="True" 
                             Background="AliceBlue" Foreground="DarkGoldenrod" Margin="0,0,10,0">
        <!-- ... -->
        </dxr:RibbonPageGroup>
        <dxr:RibbonPageGroup Caption="Edit" ShowCaptionButton="True" Background="Bisque" 
                             BorderBrush="ForestGreen" BorderThickness="2" 
                             CornerRadius="5" Padding="10,0,10,0">
          <!-- ... -->
        </dxr:RibbonPageGroup>
      </dxr:RibbonPage>
    </dxr:RibbonDefaultPageCategory>
  </dxr:RibbonControl>
</dx:ThemedWindow>

Note

The property is supported in the following DevExpress themes:

Theme FamilyThemes
Windows 11Dark, Light
Windows 10Dark, Light
Office 2019Black, Colorful, Dark Gray, White, HighContrast
Visual Studio 2019Blue, Dark, Light
Office 2016 SEBlack, Colorful, Dark Gray, White
Visual Studio 2017Blue, Dark, Light

See Also

RibbonPageGroup Class

RibbonPageGroup Members

DevExpress.Xpf.Ribbon Namespace