Padder

Layout

Adds padding around its children.

@using Spectre.Console
@using RazorConsole.Components

<Border>
    <Padder Padding="new Padding(2, 1, 2, 1)">
        <Markup Content="Padded content" />
    </Padder>
</Border>

Parameters

15
NameTypeDefaultDescription
Behavior
FocusableBoolean—Makes the scroll container a Tab stop that scrolls with the arrow keys, PageUp, PageDown, Home and End. See Focusable.
OverscrollBehaviorOverscrollBehavior—Whether scrolling continues in the parent scroll container once this one reaches its limit. See OverscrollBehavior.
Appearance
FillHeightBoolean—Whether the padder should fill the height offered by its parent.
FillWidthBoolean—Whether the padder should fill the width offered by its parent.
Events
ScrollTopChangedEventCallback<Int32>—Raised when the engine changes the scroll offset.
Common
ChildContentRenderFragment—Content to which padding will be applied.
Other
ControllerScrollController—Scrolls this container from code. See Controller.
ExpandBoolean—Whether the padder should expand to fill available space in native widget layout containers.
MarginPadding—Margin to apply outside the padded content.
OverflowOverflowMode—What happens to content taller than the padder. See Overflow.
PaddingPadding—Padding to apply as (left, top, right, bottom) in characters. Default is (0, 0, 0, 0). Example: new Padding(2, 1, 2, 1) adds 2 characters horizontally and 1 line vertically.
ScrollIdString—Stable identity of the scroll state. See ScrollId.
ScrollTopInt32—Scroll offset in rows, applied when its value changes. See ScrollTop.
ScrollbarScrollbarSettings—How the scrollbar looks and where it is drawn. See Scrollbar.
StickToBottomBoolean—Keeps the end of the content in view while it grows. See StickToBottom.

API