NumberPad class¶
Defined in
Namespace: CrissCross.Avalonia.UI.Controls
Assembly: CrissCross.Avalonia.UI.dll
Full name: CrissCross.Avalonia.UI.Controls.NumberPad
Modifiers: public
Summary¶
Represents a numeric keypad control for number input.
Applies to
net10.0, net10.0-browserwasm1.0, net10.0-desktop1.0, net9.0, net9.0-browserwasm1.0, net9.0-desktop1.0, net8.0, net8.0-ios17.5, net8.0-maccatalyst17.5, net8.0-macos14.2, net8.0-macos14.5, net8.0-tvos17.2, netstandard2.1, net471
Class hierarchy
classDiagram
class NumberPad
class TemplatedControl
TemplatedControl <|-- NumberPad
Inherits from: TemplatedControl
Constructors¶
| Name | Summary |
|---|---|
| .ctor |
Properties¶
| Name | Summary |
|---|---|
| Value | Gets or sets the current value. |
| ButtonSize | Gets or sets the button size. |
| Spacing | Gets or sets the spacing between buttons. |
| ShowDecimal | Gets or sets a value indicating whether to show the decimal button. |
| NumberPressedCommand | Gets or sets the command executed when a number is pressed. |
Fields¶
| Name | Summary |
|---|---|
| static ValueProperty | Property for [Value](# |
| static ButtonSizeProperty | Property for [ButtonSize](# |
| static SpacingProperty | Property for [Spacing](# |
| static ShowDecimalProperty | Property for [ShowDecimal](# |
| static NumberPressedCommandProperty | Property for [NumberPressedCommand](# |
| static NumberPressedEvent | Defines the [NumberPressed](# event. |
Methods¶
| Name | Summary |
|---|---|
| AppendDigit | Appends a digit to the value. |
| Clear | Clears the value. |
| Backspace | Removes the last digit from the value. |
| OnApplyTemplate | Called when the control's template is applied. In simple terms, this means the method is called just before the control is displayed. |
Events¶
| Name | Summary |
|---|---|
| NumberPressed | Occurs when a number button is pressed. |