package main import ( "fmt" "red-green/door" ) func main() { fmt.Println("Starting testdoor.go") d := door.Door{} d.Init() reset := door.Reset bold := door.Color(1, 37, 40) bolder := door.ColorText("BLI BOLD YEL ON BLUE") d.Write("Welcome to " + bolder + "door32.sys" + reset + door.CRNL + "..." + door.CRNL) key := d.Getch() message := fmt.Sprintf("Key %s%d / %x%s"+door.CRNL, bold, key, key, reset) d.Write(message) b := door.Box{20, 1} d.Write(b.Top() + door.CRNL) // or %-20s message = fmt.Sprintf("%20s", "SHAZAM!") d.Write(b.Row(message) + door.CRNL) d.Write(b.Middle() + door.CRNL) d.Write(b.Row(fmt.Sprintf("%-20s", "Meow?")) + door.CRNL) d.Write(b.Bottom() + door.CRNL) d.Write("Returning you to the BBS..." + door.CRNL) d.SleepKey(3) fmt.Println("Ending testdoor.go") }