Skip to main content

ButtonSpinner

The ButtonSpinner presents a control that includes buttons for spin-up and spin-down. The content of this button is flexible, but you will have to code quite a lot of the behavior.

Useful Properties

You will probably use these properties most often:

PropertyDescription
ButtonSpinnerLocationLocation of the spinner buttons: left or right.
ValidSpinDirectionUsed to limit spin direction: increase, decrease or none.

Example

<UserControl xmlns="https://github.com/avaloniaui"
             Padding="20">
  <ButtonSpinner Spin="OnSpin"
                 HorizontalAlignment="Center"
                 VerticalAlignment="Center">
    Press the spinner
  </ButtonSpinner>
</UserControl>
Preview
Loading Avalonia Preview...

More Information

info

For the complete API documentation about this control, see here.

info

View the source code on GitHub ButtonSpinner.cs

Discussion

Have questions or feedback? Join the conversation below.