|
UiUiUi
A user interface library for micro controller sketches based on U8g2
|
Main abstraction of a group of interface widgets. More...
#include <UIWidgetGroup.h>


Public Member Functions | |
| UIWidgetGroup (UIWidget *firstChild, UIWidget *next=nullptr) | |
| Create a widget group with a linked list of sub-widgets and a potential successor. | |
| UIArea * | render (U8G2 *display, bool force) |
| Default implementation of rendering a widget group is to render all of its sub-widgets. More... | |
| virtual void | childNeedsRendering (UIWidget *child) |
| Called by any child of this group to indicate that it wants to be rendered. More... | |
Public Member Functions inherited from UIWidget | |
| UISize | preferredSize (U8G2 *display) |
| Return the preferred size of this widget, will be called before a call to layout(). More... | |
| virtual void | layout (U8G2 *display, UIArea *area) |
| Layout widget in the given rectanglar area, will be called before first call to render(). More... | |
| virtual UIArea * | render (U8G2 *display, bool force)=0 |
| Render component in the space given in layout(). More... | |
| virtual void | setParent (UIParent *parent) |
| Set the parent widget group (if it exists). More... | |
| virtual void | childNeedsRendering (UIWidget *child)=0 |
| Called by any child of this group to indicate that it wants to be rendered. More... | |
Protected Attributes | |
| UIWidget * | firstChild |
| The first of the widgets grouped by this widget group. | |
| bool | renderChildren |
| Flag whether any child of this group needs to be rendered. | |
Protected Attributes inherited from UIWidget | |
| UIArea | dim |
| Actual area of this widget, set in layout(). | |
| UIParent * | parent |
| Reference to the group this widget is connected to. | |
Additional Inherited Members | |
Public Attributes inherited from UIWidget | |
| UIWidget * | next |
| Pointer to the next widget on the same level. | |
Protected Member Functions inherited from UIWidget | |
| UIWidget (UIWidget *next=nullptr) | |
| Initialize this widget and potentially set its successor. | |
| void | clearBox (U8G2 *display, UIArea *dimm) |
| Clear the given area. | |
| void | clearFull (U8G2 *display) |
| Clear the full area of this widget. | |
| void | clip (U8G2 *display) |
| Set U8g2's clip window to the area of this widget, should be called from render(). | |
| virtual void | computePreferredSize (U8G2 *display, UISize *preferredSize)=0 |
| Store preferred size of this widget into the preferredSize reference. More... | |
| void | signalNeedsRendering () |
| Called internally: Signals to parent that this widget needs to be rendered. | |
Main abstraction of a group of interface widgets.
A widget group organizes a number of widgets in a certain way. These organized widgets form a linked list via their "next" pointers. The widget group gets the first of these widgets as their "first widget".
As a widget group itself is also a widget, it has itself potentially a successor which allows forming another widget group on a "higher level".
Widget groups are the key to create complex interfaces with UiUiUi. Be sure to understand the concept behind them.
As with the UIWidget class, UIWidgetGroup itself only implements a tiny portion of the business logic. The derived classes actually create a semantic onto the grouped widgets, e.g. aligning them horizontally or vertically.
|
virtual |
|
virtual |
Default implementation of rendering a widget group is to render all of its sub-widgets.
Implements UIWidget.