Note: This document is auto-generated by
scripts/generate_control_reference_docs.py. Do not edit manually.
Avalonia.Controls.NumericUpDownAvalonia.ControlsAvalonia.Controlssrc/Avalonia.Controls/NumericUpDown/NumericUpDown.csTemplatedControlcontrolpublic static readonly StyledProperty<bool> AllowSpinProperty = ButtonSpinner.AllowSpinProperty.AddOwner<NumericUpDown>();public static readonly StyledProperty<Location> ButtonSpinnerLocationProperty = ButtonSpinner.ButtonSpinnerLocationProperty.AddOwner<NumericUpDown>();public static readonly StyledProperty<bool> ShowButtonSpinnerProperty = ButtonSpinner.ShowButtonSpinnerProperty.AddOwner<NumericUpDown>();public static readonly StyledProperty<bool> ClipValueToMinMaxProperty = AvaloniaProperty.Register<NumericUpDown, bool>(nameof(ClipValueToMinMax));public static readonly StyledProperty<NumberFormatInfo?> NumberFormatProperty = AvaloniaProperty.Register<NumericUpDown, NumberFormatInfo?>(nameof(NumberFormat), NumberFormatInfo.CurrentInfo);public static readonly StyledProperty<string> FormatStringProperty = AvaloniaProperty.Register<NumericUpDown, string>(nameof(FormatString), string.Empty);public static readonly StyledProperty<decimal> IncrementProperty = AvaloniaProperty.Register<NumericUpDown, decimal>(nameof(Increment), 1.0m, coerce: OnCoerceIncrement);public static readonly StyledProperty<bool> IsReadOnlyProperty = AvaloniaProperty.Register<NumericUpDown, bool>(nameof(IsReadOnly));public static readonly StyledProperty<decimal> MaximumProperty = AvaloniaProperty.Register<NumericUpDown, decimal>(nameof(Maximum), decimal.MaxValue, coerce: OnCoerceMaximum);public static readonly StyledProperty<decimal> MinimumProperty = AvaloniaProperty.Register<NumericUpDown, decimal>(nameof(Minimum), decimal.MinValue, coerce: OnCoerceMinimum);public static readonly StyledProperty<NumberStyles> ParsingNumberStyleProperty = AvaloniaProperty.Register<NumericUpDown, NumberStyles>(nameof(ParsingNumberStyle), NumberStyles.Any);public static readonly StyledProperty<string?> TextProperty = AvaloniaProperty.Register<NumericUpDown, string?>(nameof(Text), defaultBindingMode: BindingMode.TwoWay, enableDataValidation: true);public static readonly StyledProperty<IValueConverter?> TextConverterProperty = AvaloniaProperty.Register<NumericUpDown, IValueConverter?>(nameof(TextConverter), defaultBindingMode: BindingMode.OneWay);public static readonly StyledProperty<decimal?> ValueProperty = AvaloniaProperty.Register<NumericUpDown, decimal?>(nameof(Value), coerce: (s,v) => ((NumericUpDown)s).OnCoerceValue(v),public static readonly StyledProperty<string?> WatermarkProperty = AvaloniaProperty.Register<NumericUpDown, string?>(nameof(Watermark));public static readonly StyledProperty<HorizontalAlignment> HorizontalContentAlignmentProperty = ContentControl.HorizontalContentAlignmentProperty.AddOwner<NumericUpDown>();<NumericUpDown x:Name="SampleNumericUpDown" />
using Avalonia.Controls;
var control = new NumericUpDown();