Note: This document is auto-generated by
scripts/generate_control_reference_docs.py. Do not edit manually.
Avalonia.Controls.TextBoxAvalonia.ControlsAvalonia.Controlssrc/Avalonia.Controls/TextBox.csIUndoRedoHost, TemplatedControlcontrolpublic static KeyGesture? CutGesture => Application.Current?.PlatformSettings?.HotkeyConfiguration.Cut.FirstOrDefault();public static KeyGesture? CopyGesture => Application.Current?.PlatformSettings?.HotkeyConfiguration.Copy.FirstOrDefault();public static KeyGesture? PasteGesture => Application.Current?.PlatformSettings?.HotkeyConfiguration.Paste.FirstOrDefault();public static readonly StyledProperty<bool> IsInactiveSelectionHighlightEnabledProperty = AvaloniaProperty.Register<TextBox, bool>(nameof(IsInactiveSelectionHighlightEnabled), defaultValue: true);public static readonly StyledProperty<bool> ClearSelectionOnLostFocusProperty = AvaloniaProperty.Register<TextBox, bool>(nameof(ClearSelectionOnLostFocus), defaultValue: true);public static readonly StyledProperty<bool> AcceptsReturnProperty = AvaloniaProperty.Register<TextBox, bool>(nameof(AcceptsReturn));public static readonly StyledProperty<bool> AcceptsTabProperty = AvaloniaProperty.Register<TextBox, bool>(nameof(AcceptsTab));public static readonly StyledProperty<int> CaretIndexProperty = AvaloniaProperty.Register<TextBox, int>(nameof(CaretIndex), coerce: CoerceCaretIndex);public static readonly StyledProperty<bool> IsReadOnlyProperty = AvaloniaProperty.Register<TextBox, bool>(nameof(IsReadOnly));public static readonly StyledProperty<char> PasswordCharProperty = AvaloniaProperty.Register<TextBox, char>(nameof(PasswordChar));public static readonly StyledProperty<IBrush?> SelectionBrushProperty = AvaloniaProperty.Register<TextBox, IBrush?>(nameof(SelectionBrush));public static readonly StyledProperty<IBrush?> SelectionForegroundBrushProperty = AvaloniaProperty.Register<TextBox, IBrush?>(nameof(SelectionForegroundBrush));public static readonly StyledProperty<IBrush?> CaretBrushProperty = AvaloniaProperty.Register<TextBox, IBrush?>(nameof(CaretBrush));public static readonly StyledProperty<TimeSpan> CaretBlinkIntervalProperty = AvaloniaProperty.Register<TextBox, TimeSpan>(nameof(CaretBlinkInterval), defaultValue: TimeSpan.FromMilliseconds(500));public static readonly StyledProperty<int> SelectionStartProperty = AvaloniaProperty.Register<TextBox, int>(nameof(SelectionStart), coerce: CoerceCaretIndex);public static readonly StyledProperty<int> SelectionEndProperty = AvaloniaProperty.Register<TextBox, int>(nameof(SelectionEnd), coerce: CoerceCaretIndex);<TextBox x:Name="SampleTextBox" />
using Avalonia.Controls;
var control = new TextBox();