Skip to main content

SimpleButton Class

Serves as a base for classes that represent button controls.

Namespace: DevExpress.Xpf.Core

Assembly: DevExpress.Xpf.Core.v22.1.dll


public class SimpleButton :


The SimpleButton control is a standard System.Windows.Controls.Button descendant and supports all the inherited features.


Custom Button Content

Use the Content property to specify the SimpleButton‘s content.

<dx:SimpleButton x:Name="simpleButton"  Height="100" Width="226">
            <Ellipse Height="80" Width="150" Fill="#FFAFAFF3"/>
            <TextBlock TextAlignment="Center" VerticalAlignment="Center" FontSize="30">Button</TextBlock>

Customizable Glyph

Use the SimpleButton.Glyph property to assign a custom glyph.

SimpleButton Glyph

  • Assign a glyph from the DXImage extension

    <dx:SimpleButton Width="120" Height="22" Content="GlyphButton"  Glyph="{dx:DXImage Image=Close_16x16.png}"/>
  • Assign a glyph from the image file

    Add an image to your project and set the SimpleButton.Glyph property to the image path and name in this project. This code snippet sets the closebutton.png image from the images project folder as the Simple Button control’s glyph:

    <dx:SimpleButton Width="120" Height="22" Content="GlyphButton"  Glyph="images/closebutton.png"/>

Toggle Mode

Set the SimpleButton.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 SimpleButton.ButtonKind property to Repeat to enable the repeat mode.

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

See Also