menu

WinUI

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class BackstageViewButtonItem - WinUI API Reference | Syncfusion

    Show / Hide Table of Contents

    Class BackstageViewButtonItem

    Represents a button which used in a BackstageView control.

    Inheritance
    System.Object
    BackstageViewButtonItem
    Implements
    IBackstageViewItem
    System.IDisposable
    Namespace: Syncfusion.UI.Xaml.Ribbon
    Assembly: Syncfusion.Ribbon.WinUI.dll
    Syntax
    public class BackstageViewButtonItem : Button, IBackstageViewItem, IDisposable
    Remarks

    The BackstageViewButtonItem represents a normal button that responds to a Click event actions.

    Examples

    The code example below shows how to add BackstageViewButtonItem controls in a BackstageView.

     <syncfusion:RibbonBackstage Target="{Binding ElementName=rootGrid}">
          <syncfusion:BackstageView ShowBackButton="True">
              <syncfusion:BackstageView.Items>
                  <syncfusion:BackstageViewButtonItem Command="{x:Bind SaveCommand}"
                                                      Header="Save">
                      <syncfusion:BackstageViewButtonItem.Icon>
                          <FontIcon Glyph="&#xED25;" />
                      </syncfusion:BackstageViewButtonItem.Icon>
                  </syncfusion:BackstageViewButtonItem>
                  <syncfusion:BackstageViewButtonItem Command="{x:Bind CloseButtonCommand}"
                                                      Header="Close" />
          </syncfusion:BackstageView.Items>
         </syncfusion:BackstageView>
     </syncfusion:RibbonBackstage>

    Constructors

    BackstageViewButtonItem()

    Initializes a new instance of the BackstageViewButtonItem class.

    Declaration
    public BackstageViewButtonItem()

    Fields

    HeaderProperty

    Identifies the Header dependency property.

    Declaration
    public static readonly DependencyProperty HeaderProperty
    Field Value
    Type
    Microsoft.UI.Xaml.DependencyProperty

    IconProperty

    Identifies the Icon dependency property.

    Declaration
    public static readonly DependencyProperty IconProperty
    Field Value
    Type
    Microsoft.UI.Xaml.DependencyProperty

    Properties

    Header

    Gets or sets the content for the BackstageViewButtonItem header.

    Declaration
    public object Header { get; set; }
    Property Value
    Type Description
    System.Object

    The content for the BackstageViewButtonItem header. The default value is null.

    Icon

    Gets or sets an icon that appears in a BackstageViewButtonItem.

    Declaration
    public IconElement Icon { get; set; }
    Property Value
    Type Description
    Microsoft.UI.Xaml.Controls.IconElement

    The icon that appears in a BackstageViewButtonItems. The default value is null.

    Remarks

    The icon value can be assigned from the Microsoft.UI.Xaml.Controls.Symbol enumeration, or a Unicode string that references a glyph in the Segoe MDL2 Assets font. You can use character map application that comes with Windows to browse the font's glyphs and find their Unicode values. Then, use the format $#x(UNICODE) in XAML or the format \u(UNICODE) in code, where (UNICODE) is the value of the glyph that indicates the location in the font file.

    Examples
    <ribbon:BackstageViewButtonItem Header="Save">
       <ribbon:BackstageViewButtonItem.Icon>
           <SymbolIcon Symbol="Save" />
       </ribbon:BackstageViewButtonItem.Icon>
    </ribbon:BackstageViewButtonItem>
    
    <ribbon:BackstageViewButtonItem Header="Save">
       <ribbon:BackstageViewButtonItem.Icon>
           <FontIcon FontFamily="Segoe MDL2 Assets"
                     FontSize="16"
                     Glyph="&#xED25;" />
       </ribbon:BackstageViewButtonItem.Icon>
    </ribbon:BackstageViewButtonItem>
    
    <ribbon:BackstageViewButtonItem Header="Save">
       <ribbon:BackstageViewButtonItem.Icon>
           <BitmapIcon UriSource="ms-appx:///Assets/Save.png" />
       </ribbon:BackstageViewButtonItem.Icon>
    </ribbon:BackstageViewButtonItem>

    Methods

    Dispose()

    Release the unmanaged resources of BackstageView.

    Declaration
    public void Dispose()

    Dispose(Boolean)

    Release the unmanaged resources of BackstageViewButtonItem control.

    Declaration
    protected virtual void Dispose(bool disposing)
    Parameters
    Type Name Description
    System.Boolean disposing

    true if unmanaged resources should be disposed; otherwise, false.

    OnCreateAutomationPeer()

    Declaration
    protected override AutomationPeer OnCreateAutomationPeer()
    Returns
    Type
    Microsoft.UI.Xaml.Automation.Peers.AutomationPeer

    Implements

    IBackstageViewItem
    System.IDisposable
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved