Gooey GUI Library
|
Header file for the GooeyList widget. More...
#include "common/gooey_common.h"
Go to the source code of this file.
Functions | |
GooeyList * | GooeyList_Create (int x, int y, int width, int height, void(*callback)(int index)) |
Creates a widget. | |
void | GooeyList_AddItem (GooeyList *list, const char *title, const char *description) |
Adds an item to the specified list widget. | |
void | GooeyList_ClearItems (GooeyList *list) |
Clears all items from the specified list widget. | |
void | GooeyList_ShowSeparator (GooeyList *list, bool state) |
Toggles the visibility of the separator in a list widget. | |
void | GooeyList_UpdateItem (GooeyList *list, size_t item_index, const char *title, const char *description) |
Header file for the GooeyList widget.
Provides functionality for creating and managing list widgets within a GooeyWindow.
void GooeyList_AddItem | ( | GooeyList * | list, |
const char * | title, | ||
const char * | description | ||
) |
Adds an item to the specified list widget.
list | The list widget to which the item will be added. |
title | The title of the list item. |
description | The description of the list item. |
void GooeyList_ClearItems | ( | GooeyList * | list | ) |
Clears all items from the specified list widget.
Removes all list items from the provided list widget.
list | The list widget to be cleared. |
GooeyList * GooeyList_Create | ( | int | x, |
int | y, | ||
int | width, | ||
int | height, | ||
void(*)(int index) | callback | ||
) |
Creates a widget.
Creates a new list widget and attaches it to the given window.
x | The x-coordinate of the list widget's position. |
y | The y-coordinate of the list widget's position. |
width | The width of the list widget. |
height | The height of the list widget. |
callback | The function to be called when an item is selected. |
void GooeyList_ShowSeparator | ( | GooeyList * | list, |
bool | state | ||
) |
Toggles the visibility of the separator in a list widget.
Enables or disables the visual separator between list items.
list | The list widget. |
state | true to show the separator, false to hide it. |
void GooeyList_UpdateItem | ( | GooeyList * | list, |
size_t | item_index, | ||
const char * | title, | ||
const char * | description | ||
) |