spruce/border

Border styles and the glyphs that draw them, shared by spruce/box and spruce/table.

Types

A border style. Hidden draws nothing; Custom supplies its own glyphs.

pub type Border {
  Normal
  Rounded
  Thick
  Double
  Hidden
  Block
  Custom(BorderChars)
}

Constructors

  • Normal
  • Rounded
  • Thick
  • Double
  • Hidden
  • Block
  • Custom(BorderChars)

The characters used to draw a visible border.

pub type BorderChars {
  BorderChars(
    top_left: String,
    top: String,
    top_right: String,
    right: String,
    bottom_right: String,
    bottom: String,
    bottom_left: String,
    left: String,
  )
}

Constructors

  • BorderChars(
      top_left: String,
      top: String,
      top_right: String,
      right: String,
      bottom_right: String,
      bottom: String,
      bottom_left: String,
      left: String,
    )

Values

pub fn chars(border: Border) -> BorderChars

The glyph set for a border style.

✨ Search Document