Skip to main content

SimpleButton.PressedBorderColor Property

Specifies the border color of the button in a pressed state.

Namespace: DevExpress.XamarinForms.Editors

Assembly: DevExpress.XamarinForms.Editors.dll

NuGet Package: DevExpress.XamarinForms.Editors

Declaration

public Color PressedBorderColor { get; set; }

Property Value

Type Description
Color

The border color of the button in a pressed state.

Example

This example shows how to customize button appearance and handle the button click event.

Button State

Default Appearance

Custom Appearance

Default

Pressed

Disabled

  1. Add the delete.png icon file to your platform-specific projects:

    • Android
      Add the icon file to the Resources/drawable folder.
    • iOS
      Double-click the Assets.xcassets asset catalog, create a new delete image set, and add the icon image to this image set.
  2. Use the following properties to adjust the button’s appearance and handle the Clicked event to clear label1 on button tap:

    <dxe:SimpleButton Text = "Clear" 
                      Icon = "delete" 
                      BorderThickness="2"
                      BorderColor="Black"
                      PressedBorderColor="DarkOrange"
                      DisabledBorderColor="DarkGray"
                      TextColor="Black"
                      PressedTextColor="White"
                      DisabledTextColor="DarkGray"
                      IconColor="Black"
                      PressedIconColor="White"
                      DisabledIconColor="DarkGray"
                      BackgroundColor="Beige"
                      DisabledBackgroundColor="Brown"
                      PressedBackgroundColor="Gray"
                      CornerMode = "Round"        
                      CornerRadius="10"
                      Clicked = "SimpleButton_Clicked"/>
    
    private void SimpleButton_Clicked(object sender, EventArgs e) {
        label1.Text = "";
    }
    
See Also