-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcheckbox.h
More file actions
23 lines (21 loc) · 1.05 KB
/
Copy pathcheckbox.h
File metadata and controls
23 lines (21 loc) · 1.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#ifndef _CHECKBOX_H_
#define _CHECKBOX_H_
#include "widget.h"
typedef struct wwCheckbox wwCheckbox;
typedef void (*wwCheckboxCallback)(wwCheckbox *checkbox, wwWindowAndRenderer *windowAndRenderer);
struct wwCheckbox
{
wwWidget widget;
};
wwCheckbox* wwCheckbox_Create(wwWindowAndRenderer *windowAndRenderer, wchar_t *text, int x, int y, int width, int height);
void wwCheckbox_SetCallback(wwCheckbox *checkBox, wwCheckboxCallback callback, void *userData);
int wwCheckbox_IsChecked(wwCheckbox *checkBox, wwWindowAndRenderer *windowAndRenderer);
void wwCheckbox_SetChecked(wwCheckbox *checkBox, wwWindowAndRenderer *windowAndRenderer, int checked);
void wwCheckbox_SetText(wwCheckbox *checkbox, wchar_t *text);
void wwCheckbox_SetX(wwCheckbox *checkbox, int x);
void wwCheckbox_SetY(wwCheckbox *checkbox, int y);
void wwCheckbox_SetWidth(wwCheckbox *checkbox, int width);
void wwCheckbox_SetHeight(wwCheckbox *checkbox, int height);
/* returns malloc() pointer, should free() after usage */
wchar_t* wwCheckbox_GetText(wwCheckbox *checkbox);
#endif /* _CHECKBOX_H_ */