tview icon indicating copy to clipboard operation
tview copied to clipboard

Using widgets for simple console interaction without using entire screen, is that possible?

Open elsni opened this issue 1 year ago • 1 comments

I would like to use widgets for fancy user interaction in small programs without using the whole screen.

like the screenshot below. The screenshot is a montage, actually the whole screen is cleared and the menu is put in the upper left corner image

(how) is it possible?

elsni avatar Nov 05 '23 20:11 elsni

I don't think tview can be used without using the entire screen. It's based on tcell which is a library for full-screen applications.

But if you're ok with using the entire screen, you'll want to use a Pages component at the root which contains your main text (I assume it's a TextView?) and your List on top. Finding out where to place the list depends a bit on what your main component is. Again, if it's a TextView, the GetOriginalLineCount() and GetScrollOffset() functions might help.

rivo avatar Nov 06 '23 16:11 rivo