Class StatusTextElementBuilder
- Namespace
- SharpConsoleUI.Panel.Builders
- Assembly
- SharpConsoleUI.dll
Fluent builder for StatusTextElement.
public class StatusTextElementBuilder : IPanelElementBuilder
- Inheritance
-
StatusTextElementBuilder
- Implements
- Inherited Members
- Extension Methods
Constructors
StatusTextElementBuilder(string)
Initializes a new builder with the specified text.
public StatusTextElementBuilder(string text)
Parameters
textstringThe markup text to display.
Methods
Build()
Builds and returns the configured panel element.
public IPanelElement Build()
Returns
OnClick(Action)
Sets the click handler.
public StatusTextElementBuilder OnClick(Action handler)
Parameters
handlerAction
Returns
WithColor(Color)
Sets the text color.
public StatusTextElementBuilder WithColor(Color color)
Parameters
colorColor
Returns
WithName(string)
Sets the element name.
public StatusTextElementBuilder WithName(string name)
Parameters
namestring