TextArea
ConsoleMonster.Interactive
Draws a TextAreaEditor: the text soft-wrapped at word boundaries behind a muted bar, a fixed number of visible rows scrolled to keep the caret in view, a placeholder while empty, and the caret reported to the CaretSlot. The layout it computes is what Up and Down move through.
Inheritance
- InputControl
- TextArea
Usage
Explore 36 API references to this type
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by 18
- Extension method TextArea.WithEnabled
- Extension method TextArea.WithHeight
- Extension method TextArea.WithLabel
- Extension method TextArea.WithMaxLength
- Extension method TextArea.WithPlaceholder
- Extension method TextArea.WithScrollRow
- Extension method TextArea.WithTabIndex
- Extension method TextArea.WithValidationMessage
- Extension method TextArea.WithValue
- Method TextAreaFluent.WithEnabled
- Method TextAreaFluent.WithHeight
- Method TextAreaFluent.WithLabel
- Method TextAreaFluent.WithMaxLength
- Method TextAreaFluent.WithPlaceholder
- Method TextAreaFluent.WithScrollRow
- Method TextAreaFluent.WithTabIndex
- Method TextAreaFluent.WithValidationMessage
- Method TextAreaFluent.WithValue
Accepted by parameters 18
- Extension method TextArea.WithEnabled
- Extension method TextArea.WithHeight
- Extension method TextArea.WithLabel
- Extension method TextArea.WithMaxLength
- Extension method TextArea.WithPlaceholder
- Extension method TextArea.WithScrollRow
- Extension method TextArea.WithTabIndex
- Extension method TextArea.WithValidationMessage
- Extension method TextArea.WithValue
- Method TextAreaFluent.WithEnabled
- Method TextAreaFluent.WithHeight
- Method TextAreaFluent.WithLabel
- Method TextAreaFluent.WithMaxLength
- Method TextAreaFluent.WithPlaceholder
- Method TextAreaFluent.WithScrollRow
- Method TextAreaFluent.WithTabIndex
- Method TextAreaFluent.WithValidationMessage
- Method TextAreaFluent.WithValue
Constructors
public TextArea(string name, string? value = null) #Creates a named multiline input using the shared text-area editor.
Parameters
- name string
- The application-state key.
- value string? = null
- The initial text.
Inherited Methods
public bool HandleInput(InputEvent input, RenderContext context) #Parameters
- input InputEvent
- context RenderContext
Returns
boolpublic Size Measure(Constraints constraints, RenderContext context) #Parameters
- constraints Constraints
- context RenderContext
Returns
Sizepublic void Render(Region region, RenderContext context) #Parameters
- region Region
- context RenderContext
Properties
Inherited Properties
Inherited Events
public event EventHandler<AppValueChangedEventArgs>? Changed #Extension Methods
public static TextArea WithEnabled(TextArea textArea, bool value = true) #Sets InputControl.Enabled: Whether the control accepts input and participates in focus traversal.
Parameters
- textArea ConsoleMonster.Interactive.TextArea
- The instance.
- value bool = true
- The value (default true).
public static TextArea WithHeight(TextArea textArea, int value) #Sets TextArea.Height: The visible rows (default 6).
Parameters
- textArea ConsoleMonster.Interactive.TextArea
- The instance.
- value int
- The value.
public static TextArea WithLabel(TextArea textArea, string? value) #Sets InputControl.Label: The visible label, or null to use the name.
Parameters
- textArea ConsoleMonster.Interactive.TextArea
- The instance.
- value string?
- The value.
public static TextArea WithMaxLength(TextArea textArea, int value) #Sets TextArea.MaxLength: The maximum text length, in UTF-16 units.
Parameters
- textArea ConsoleMonster.Interactive.TextArea
- The instance.
- value int
- The value.
public static TextArea WithPlaceholder(TextArea textArea, string? value) #Sets TextArea.Placeholder: Muted text shown when the value is empty.
Parameters
- textArea ConsoleMonster.Interactive.TextArea
- The instance.
- value string?
- The value.
public static TextArea WithScrollRow(TextArea textArea, int value) #Sets TextArea.ScrollRow: The first visible row (kept between frames).
Parameters
- textArea ConsoleMonster.Interactive.TextArea
- The instance.
- value int
- The value.
public static TextArea WithTabIndex(TextArea textArea, int value) #Sets InputControl.TabIndex: Focus order; equal values preserve declaration order.
Parameters
- textArea ConsoleMonster.Interactive.TextArea
- The instance.
- value int
- The value.
public static TextArea WithValidationMessage(TextArea textArea, string? value) #Sets InputControl.ValidationMessage: The current validation message below the control, or null.
Parameters
- textArea ConsoleMonster.Interactive.TextArea
- The instance.
- value string?
- The value.
public static TextArea WithValue(TextArea textArea, string value) #Sets TextArea.Value: The multiline text value.
Parameters
- textArea ConsoleMonster.Interactive.TextArea
- The instance.
- value string
- The value.