Add initial FIGlet docs

This commit is contained in:
Patrik Svensson 2020-11-22 03:21:10 +01:00 committed by Patrik Svensson
parent a59e0dcb21
commit a5125d640c

33
docs/input/figlet.md Normal file
View File

@ -0,0 +1,33 @@
Title: Figlet
Order: 5
---
Spectre.Console can render [FIGlet](http://www.figlet.org/) text by using the `FigletText` class.
# Default font
```csharp
AnsiConsole.Render(
new FigletText("Hello")
.LeftAligned()
.Color(Color.Red));
```
```text
_ _ _ _
| | | | ___ | | | | ___
| |_| | / _ \ | | | | / _ \
| _ | | __/ | | | | | (_) |
|_| |_| \___| |_| |_| \___/
```
# Custom font
```csharp
var font = FigletFont.Load("starwars.flf");
AnsiConsole.Render(
new FigletText(font, "Hello")
.LeftAligned()
.Color(Color.Red));
```