BinaryRibbonBackstageApplicationMenu
An application button whose menu opens as a panel across the width of the window – a backstage view - holding whatever elements the application puts in it.
public class BinaryRibbonBackstageApplicationMenu : MenuItem, IBinaryRibbonKeyTipControl, IBinaryRibbonApplicationMenu
Inherits from / implements: MenuItem, IBinaryRibbonKeyTipControl, IBinaryRibbonApplicationMenu
Remarks
Assign it to BinaryRibbonBarPanel.ApplicationMenu in place of a
BinaryRibbonApplicationMenu. Its items are shown as they are, not wrapped as menu
items, in a panel as wide as the BinaryRibbonWindow's Width less 8 logical
pixels: lay out an Info, Open or Print page with ordinary WPF elements. A click on a
MenuItem inside it closes it.
Examples
<bm:BinaryRibbonBarPanel.ApplicationMenu>
<bm:BinaryRibbonBackstageApplicationMenu bm:BinaryKeyTip.AccessKey="F">
<Grid Height="420">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="180" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<StackPanel>
<bm:BinaryRibbonMenuItem Header="Info" Click="OnShowInfo" />
<bm:BinaryRibbonMenuItem Header="Export" Click="OnShowExport" />
<bm:BinaryRibbonMenuItem Header="Close" Click="OnCloseDocument" />
</StackPanel>
<ContentControl Grid.Column="1" Content="{Binding BackstagePage}" />
</Grid>
</bm:BinaryRibbonBackstageApplicationMenu>
</bm:BinaryRibbonBarPanel.ApplicationMenu>See also
Members at a glance
| Constructors | |
|---|---|
BinaryRibbonBackstageApplicationMenu | Creates an empty backstage menu. A click on any menu item inside it closes it. |
| Properties | |
ButtonImage | Gets or sets the picture on the application button. |
IsOpen | Gets or sets whether the backstage panel is open. |
| Methods | |
GetContainerForItemOverride | Creates a BinaryRibbonMenuItem; not used by this menu, whose items need no container. |
IsItemItsOwnContainerOverride | Reports that every item is shown as it is, without a container. |
OnApplyTemplate | Takes the template's button and drop-down. |
OnPopupWindowClosed | Called when the panel closes; the base implementation clears IsOpen. |
OnPopupWindowOpen | Called when the panel opens; the base implementation lines up the copy of the application button
drawn over it, and sets IsOpen. |
| Fields | |
ButtonImageProperty | Identifies the ButtonImage dependency property. |
IsOpenProperty | Identifies the IsOpen dependency property. |
Constructors
Properties
ButtonImage
Gets or sets the picture on the application button.
- Value
- The default is the current skin's application button picture.
Remarks
While BinaryRibbonBuiltInSkinController.Skin is RibbonSkin.Windows7, a
picture assigned here is replaced by the built-in Windows 7 one.
IsOpen
Gets or sets whether the backstage panel is open.
- Value
- The default is
false.
Remarks
Opening or closing it also closes the commands of a tabs-only ribbon if they are dropped down
(BinaryRibbonBarPanel.CollapseRibbonBarCommand).
Methods
GetContainerForItemOverride
Creates a BinaryRibbonMenuItem; not used by this menu, whose items need no container.
Returns
A new BinaryRibbonMenuItem.
IsItemItsOwnContainerOverride
Reports that every item is shown as it is, without a container.
Parameters
item- The item.
Returns
Always true.
OnApplyTemplate
Takes the template's button and drop-down.
OnPopupWindowClosed
Called when the panel closes; the base implementation clears IsOpen.
Parameters
sender- The drop-down.
e- Not used.
OnPopupWindowOpen
Called when the panel opens; the base implementation lines up the copy of the application button
drawn over it, and sets IsOpen.
Parameters
sender- The drop-down.
e- Not used.
Fields
ButtonImageProperty static
Identifies the ButtonImage dependency property.
IsOpenProperty static
Identifies the IsOpen dependency property.