etui/widgets/line

Types

Horizontal or vertical divider with optional color.

pub type Line {
  Line(style: LineStyle, fg: style.Color)
}

Constructors

Drawing style for lines. Currently only Solid (─ / │).

pub type LineStyle {
  Solid
}

Constructors

  • Solid

Values

pub fn line_new() -> Line

New solid line with default terminal color.

pub fn render_horizontal(
  buf: buffer.Buffer,
  area: geometry.Rect,
  l: Line,
) -> buffer.Buffer

Render horizontal line.

pub fn render_vertical(
  buf: buffer.Buffer,
  area: geometry.Rect,
  l: Line,
) -> buffer.Buffer

Render vertical line.

pub fn with_color(l: Line, color: style.Color) -> Line

Set the line color.

Search Document