Update README and README demo program to match

This commit is contained in:
Jonathan Daugherty 2022-06-19 21:52:45 -07:00
parent 410fcaa212
commit 322bd7d0bb
2 changed files with 3 additions and 1 deletions

View File

@ -20,6 +20,7 @@ Example
Here's an example interface (see `programs/ReadmeDemo.hs`):
```
joinBorders $
withBorderStyle unicode $
borderWithLabel (str "Hello!") $
(center (str "Left") <+> vBorder <+> center (str "Right"))

View File

@ -1,12 +1,13 @@
module Main where
import Brick (Widget, simpleMain, (<+>), str, withBorderStyle)
import Brick (Widget, simpleMain, (<+>), str, withBorderStyle, joinBorders)
import Brick.Widgets.Center (center)
import Brick.Widgets.Border (borderWithLabel, vBorder)
import Brick.Widgets.Border.Style (unicode)
ui :: Widget ()
ui =
joinBorders $
withBorderStyle unicode $
borderWithLabel (str "Hello!") $
(center (str "Left") <+> vBorder <+> center (str "Right"))