mirror of
https://github.com/nsnail/spectre.console.git
synced 2025-04-17 17:32:50 +08:00

Fixes some tree rendering problems where lines were not properly drawn at some levels during some circumstances. * Change the API back to only allow one root. * Now uses a stack based approach to rendering instead of recursion. * Removes the need for measuring the whole tree in advance. Leave this up to each child to render.
626 B
626 B
Title: Figlet Order: 50 RedirectFrom: figlet
Spectre.Console can render FIGlet text by using the FigletText
class.
Default font
AnsiConsole.Render(
new FigletText("Hello")
.LeftAligned()
.Color(Color.Red));
_ _ _ _
| | | | ___ | | | | ___
| |_| | / _ \ | | | | / _ \
| _ | | __/ | | | | | (_) |
|_| |_| \___| |_| |_| \___/
Custom font
var font = FigletFont.Load("starwars.flf");
AnsiConsole.Render(
new FigletText(font, "Hello")
.LeftAligned()
.Color(Color.Red));