Is it possible to have an multiple areas on screen? #615
-
I want a way to show two areas next to each other. Is this possible somehow? I tried to use sections but that doesn't work as I expected it to. Any help will be greatly appreciated :) var done = make(chan bool)
pterm.DefaultSection.Println("This is a section!")
area, _ := pterm.DefaultArea.WithCenter().Start()
area.Update("aaaaaaaaaaaaaaaaaaaaaaaaaa")
go func() {
defer area.Stop()
for i := 0; i < 1; i++ {
area.Update("bbbbbbbbbbbbbbbbbbbbbbbbbb")
}
done <- true
}()
pterm.DefaultSection.WithLevel(1).Println("This is another section!") |
Beta Was this translation helpful? Give feedback.
Answered by
MarvinJWendt
Jan 21, 2024
Replies: 1 comment 1 reply
-
Hi, this feature is not directly supported by PTerm, but you could use the |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
MarvinJWendt
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi, this feature is not directly supported by PTerm, but you could use the
PanelPrinter
to print two panels next to each other. You can use the output of thePanelPrinter
(Srender()
) and pipe that into anAreaPrinter
. Let me know if that works for you!