69 lines
1.7 KiB
C
69 lines
1.7 KiB
C
/* Generated by k2c from runtime/button_props.kry. */
|
|
#ifndef K_RUNTIME_BUTTON_PROPS_H
|
|
#define K_RUNTIME_BUTTON_PROPS_H
|
|
|
|
#include <stdint.h>
|
|
#include <stdbool.h>
|
|
|
|
#ifndef KIR_STRING_VALUE_DEFINED
|
|
#define KIR_STRING_VALUE_DEFINED
|
|
#include <stddef.h>
|
|
#include <string.h>
|
|
/* Immutable borrowed UTF-8 bytes; length preserves embedded nulls. */
|
|
typedef struct String { const char *data; size_t length; } String;
|
|
static inline String StringView(const char *data, size_t length) {
|
|
String value = {data, length};
|
|
return value;
|
|
}
|
|
static inline bool StringEqual(String a, String b) {
|
|
return a.length == b.length && (a.length == 0 || memcmp(a.data, b.data, a.length) == 0);
|
|
}
|
|
#endif
|
|
#include "ui_control_props.generated.h"
|
|
#include "ui_menu_types.h"
|
|
|
|
typedef struct ButtonProps {
|
|
Rectangle bounds;
|
|
const char* label;
|
|
int32_t font;
|
|
int32_t id;
|
|
ButtonTone tone;
|
|
ButtonEmphasis emphasis;
|
|
ControlSize size;
|
|
bool disabled;
|
|
bool loading;
|
|
bool selected;
|
|
bool full_width;
|
|
bool pill;
|
|
bool circle;
|
|
Texture2D icon;
|
|
int32_t icon_type;
|
|
IconPlacement icon_placement;
|
|
bool icon_only;
|
|
bool square;
|
|
const char* image_asset_path;
|
|
Rectangle image_bounds;
|
|
Rectangle image_source;
|
|
Vector2 image_origin;
|
|
float image_rotation;
|
|
Color image_tint;
|
|
int32_t image_fit;
|
|
Color image_background;
|
|
bool swatch;
|
|
Color swatch_color;
|
|
int32_t menu_id;
|
|
const MenuItem* items;
|
|
int32_t item_count;
|
|
int32_t* open;
|
|
int32_t* activated_id;
|
|
bool menu;
|
|
bool split;
|
|
bool arrow;
|
|
bool info;
|
|
int32_t direction;
|
|
ButtonState state;
|
|
ControlStyle style;
|
|
} ButtonProps;
|
|
|
|
#endif /* K_RUNTIME_BUTTON_PROPS_H */
|