|
ginnOS
The reference: libc, the libraries and the kernel
|
idunn: what floats over a window: tooltips (the primary colour, small text), popovers (a card next to a widget) and dialogs (a card in the middle of the window over the overlay colour, with buttons at the bottom right; the window behind gets no input). More...
Macros | |
| #define | TIP_PAD_X 10 |
| #define | TIP_PAD_Y 5 |
| #define | TIP_GAP 6 |
| #define | POPOVER_WIDTH 288 |
| #define | POPOVER_GAP 4 |
| #define | MARGIN 28 |
Functions | |
| void | idunn_tooltip_show (idunn_widget_t *w) |
| show w's tooltip over it | |
| void | idunn_popover (idunn_widget_t *owner, idunn_widget_t *content) |
| a popover: content in a card under owner; a press outside it or Escape closes it. | |
| void | idunn_popover_close (idunn_widget_t *inside) |
| close the popover a widget is in | |
| idunn_widget_t * | idunn_dialog (const char *title, const char *description) |
| a dialog: a card with a title and a description (or NULL), in the middle of the window over the overlay colour. | |
| idunn_widget_t * | idunn_dialog_content (idunn_widget_t *dialog) |
| idunn_widget_t * | idunn_dialog_add_button (idunn_widget_t *dialog, const char *text, idunn_variant_t variant, idunn_callback_t on_click, void *data) |
| a button at the bottom right: Cancel as outline, the action primary or destructive | |
| void | idunn_dialog_open (idunn_widget_t *owner, idunn_widget_t *dialog) |
| show a dialog over the window of owner; the window owns it then | |
| void | idunn_dialog_close (idunn_widget_t *dialog) |
| void | idunn_dialog_dismiss (idunn_window_t *win) |
| close the dialog in win (Escape) | |
idunn: what floats over a window: tooltips (the primary colour, small text), popovers (a card next to a widget) and dialogs (a card in the middle of the window over the overlay colour, with buttons at the bottom right; the window behind gets no input).
| #define TIP_PAD_X 10 |
| #define TIP_PAD_Y 5 |
| #define TIP_GAP 6 |
| #define POPOVER_WIDTH 288 |
| #define POPOVER_GAP 4 |
| #define MARGIN 28 |
| void idunn_tooltip_show | ( | idunn_widget_t * | w | ) |
show w's tooltip over it
| void idunn_popover | ( | idunn_widget_t * | owner, |
| idunn_widget_t * | content ) |
a popover: content in a card under owner; a press outside it or Escape closes it.
the popover owns content. it is 288 wide, or as wide as content when content has a larger width (idunn_set_size).
| void idunn_popover_close | ( | idunn_widget_t * | inside | ) |
close the popover a widget is in
| idunn_widget_t * idunn_dialog | ( | const char * | title, |
| const char * | description ) |
a dialog: a card with a title and a description (or NULL), in the middle of the window over the overlay colour.
add content to idunn_dialog_content, then the buttons; a button closes the dialog and then calls its on_click (with the dialog). Escape closes it too.
| idunn_widget_t * idunn_dialog_content | ( | idunn_widget_t * | dialog | ) |
| idunn_widget_t * idunn_dialog_add_button | ( | idunn_widget_t * | dialog, |
| const char * | text, | ||
| idunn_variant_t | variant, | ||
| idunn_callback_t | on_click, | ||
| void * | data ) |
a button at the bottom right: Cancel as outline, the action primary or destructive
| void idunn_dialog_open | ( | idunn_widget_t * | owner, |
| idunn_widget_t * | dialog ) |
show a dialog over the window of owner; the window owns it then
| void idunn_dialog_close | ( | idunn_widget_t * | dialog | ) |
| void idunn_dialog_dismiss | ( | idunn_window_t * | win | ) |
close the dialog in win (Escape)