Commit graph

2 commits

Author SHA1 Message Date
Simon Howard
3626db3888 textscreen: Set parent pointer for conditionals.
We rely on the parent pointer to determine if the widget is being
hovered over. Set the parent pointer so that the background is set
properly for a widget in a conditional container.
2016-06-09 23:10:59 -04:00
Simon Howard
74f35cea77 textscreen: Add widget for conditionally hiding.
A common pattern when using libtextscreen is to want to show or hide
particular UI components depending on the values of particular
variables. It is also common to want to only add things to the UI if
a particular boolean condition is true. Add a new conditional widget
to cover the first case, and a convenience TXT_If() function for the
latter.
2016-06-05 00:04:59 -04:00