Back to Devexpress

SimpleButton.ButtonKind Property

wpf-devexpress-dot-xpf-dot-core-dot-simplebutton-54b9e077.md

latest2.5 KB
Original Source

SimpleButton.ButtonKind Property

Gets a value that specifies the button’s behavior (simple button, repeat button, or toggle button). This is a dependency property.

Namespace : DevExpress.Xpf.Core

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

NuGet Package : DevExpress.Wpf.Core

Declaration

csharp
public ButtonKind ButtonKind { get; set; }
vb
Public Property ButtonKind As ButtonKind

Property Value

TypeDescription
ButtonKind

One of the ButtonKind enumeration values.

|

Available values:

NameDescription
Simple

Represents a simple button. The Click event is fired each time a button is clicked.

| | Repeat |

Represents the repeat button. The Click event is repeatedly fired until a button is released.

| | Toggle |

Represents a toggle button. Clicking a button toggles its state (pressed or released).

|

Remarks

Toggle Mode

Set the ButtonKind property to Toggle to enable toggle mode.

By default, toggle mode supports two states, True and False. To enable the Indeterminate state, set the SimpleButton.IsThreeState property to true.

In toggle mode , the following events occur on mouse click:

Repeat Mode

In the repeat mode , the Click event is repeatedly fired until a button is released.

Set the ButtonKind property to Repeat to enable the repeat mode.

Use the SimpleButton.Delay and SimpleButton.Interval properties to control the repeat behavior.

See Also

SimpleButton Class

SimpleButton Members

DevExpress.Xpf.Core Namespace