PanelComponent class
A boxed panel component with optional title.
PanelComponent(
content: 'Hello, World!',
title: 'Greeting',
).render();
- Inheritance
-
- Object
- Model
- ViewComponent
- StaticComponent
- DisplayComponent
- PanelComponent
- Available extensions
Constructors
- PanelComponent({required Object content, String? title, PanelAlignment titleAlign = PanelAlignment.left, PanelAlignment contentAlign = PanelAlignment.left, PanelBoxCharSet chars = PanelBoxChars.rounded, int padding = 1, int? width, Style? borderStyle, RenderConfig renderConfig = const RenderConfig()})
-
const
Properties
- borderStyle → Style?
-
final
- chars → PanelBoxCharSet
-
final
- content → Object
-
final
- contentAlign → PanelAlignment
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- lineCount → int
-
Number of lines in render.
no setterinherited
- padding → int
-
final
- renderConfig → RenderConfig
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- title → String?
-
final
- titleAlign → PanelAlignment
-
final
- width → int?
-
final
Methods
-
init(
) → Cmd? -
Returns an optional command to execute on program startup.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
render(
) → String -
Renders the component as a string.
override
-
toString(
) → String -
A string representation of this object.
inherited
-
update(
Msg msg) → (ViewComponent, Cmd?) -
Updates the component state in response to a message.
inherited
-
view(
) → String -
Renders the current model state for display.
inherited
-
writelnTo(
Console io) → void -
Available on DisplayComponent, provided by the DisplayComponentExtension extension
Renders the component and writes it to the console.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited