Class Banner
Pascal-style banners. Two flavours: a framed Box for titles,
and a per-line Gradient(string[], Color, Color, bool) for fancier startup screens.
public static class Banner
- Inheritance
-
Banner
- Inherited Members
Methods
Box(string, Color?, int, int, BoxAlign)
Print text wrapped in a single-line frame. Uses
box-drawing glyphs when the terminal can render them, falls back to
+--+ otherwise.
public static void Box(string text, Color? fg = null, int padding = 1, int width = 0, BoxAlign align = BoxAlign.Left)
Parameters
Box(string[], Color?, int, int, BoxAlign)
Print one frame around all lines. The box is
sized to the longest line, or to width total
cells if larger. Pass FillWidth to span the
current terminal width. align picks how lines
shorter than the inner content width are positioned.
public static void Box(string[] lines, Color? fg = null, int padding = 1, int width = 0, BoxAlign align = BoxAlign.Left)
Parameters
Gradient(string[], Color, Color, bool)
Print lines with a per-line color interpolated from
from to to. Both colors must be
truecolor; if either is a Standard16 entry the gradient collapses to
from for every line.
public static void Gradient(string[] lines, Color from, Color to, bool bold = true)