Sigil

Scroll

A scroll area.

It measures its content; .extent(f32 or Signal<f32>) sets a known content height instead.

GUITUIRuns in the browserscroll

Preview

Scroll, Default, light themeScroll, Default, dark theme

Usage example

fn scroll_demo() -> NodeBuilder {    container()        .layout(LayoutStyle::flex_column().fill_width().height(120.0))        .child(scroll(scroll_lines()).extent(280.0).fill())}
fn scroll_demo() -> NodeBuilder {  container()    .layout(      LayoutStyle::flex_column()        .fill_width()        .height(120.0),    )    .child(      scroll(scroll_lines())        .extent(280.0)        .fill(),    )}

States

All 4 captured states, each drawn by the window host and by the terminal host.

Default

  • Scroll, Default, light themeScroll, Default, dark theme
    Default
  • Scroll, Hover, light themeScroll, Hover, dark theme
    Hover

Auto

  • Scroll, Auto: Default, light themeScroll, Auto: Default, dark theme
    Default
  • Scroll, Auto: Hover, light themeScroll, Auto: Hover, dark theme
    Hover

API

NameSignaturePurpose
scrollfn scroll(content: NodeBuilder) -> ScrollBuilderA scroll area. It measures its content; .extent(f32 or Signal<f32>) sets a known content height instead.