DropDownButton Class

DevZest WPF Docking

DropDownButton Class
Represents a button that drops down a context menu.
Inheritance Hierarchy
SystemObject  System.Windows.ThreadingDispatcherObject
    System.WindowsDependencyObject
      System.Windows.MediaVisual
        System.WindowsUIElement
          System.WindowsFrameworkElement
            System.Windows.ControlsControl
              System.Windows.ControlsContentControl
                System.Windows.Controls.PrimitivesButtonBase
                  System.Windows.ControlsButton
                    DevZest.WindowsDropDownButton

Namespace: DevZest.Windows
Assembly: DevZest.WpfDocking (in DevZest.WpfDocking.dll) Version: 2.5.0.0 (2.5.5912.0)
Syntax
public class DropDownButton : Button
Public Class DropDownButton
	Inherits Button

The DropDownButton type exposes the following members.

Constructors
  NameDescription
Public methodDropDownButton
Initializes a new instance of the DropDownButton class
Top
Properties
  NameDescription
Public propertyDropDown
Gets or sets the drop down ContextMenu. This is a dependency property.
Public propertyIsDropDownOpen
Gets a value that indicates whether the drop down ContextMenu is visible. This is a dependency property.
Top
Fields
  NameDescription
Public fieldStatic memberDropDownProperty
Identifies the DropDown dependency property.
Public fieldStatic memberIsDropDownOpenProperty
Identifies the IsDropDownOpen dependency property.
Top
Remarks
DropDown property defines the ContextMenu to drop down. IsDropDownOpen property determines if the drop down ContextMenu is open.
Examples
XAML
<Window
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:dz="http://schemas.devzest.com/presentation"
    SizeToContent="WidthAndHeight">
    <dz:DropDownButton Content="Click">
        <dz:DropDownButton.DropDown>
            <ContextMenu>
                <MenuItem Header="MenuItem 1" />
                <MenuItem Header="MenuItem 2" />
            </ContextMenu>
        </dz:DropDownButton.DropDown>
    </dz:DropDownButton>
</Window>
See Also