Files
kryon/include/ui_node_registry_props.generated.h
T
waozi 641de8de6a Declare the node-registry host in its props header
Move the ten NodeType queries, including NodeTypeAt's const NodeType* return
and NodeTypeSnippet's char-buffer output, into runtime/node_registry_props.kry
as "#extern #export" declarations, so the tracked props header carries the
public ABI and include/ui_node_registry.h is deleted. kryon.h and the host
module include the props header directly.

Gates: generated-runtime-parity-test, fast-test, and the refreshed public-API
snapshot pass.
2026-09-21 01:01:23 -03:00

51 lines
1.5 KiB
C

/* Generated by k2c from runtime/node_registry_props.kry. */
#ifndef K_RUNTIME_NODE_REGISTRY_PROPS_H
#define K_RUNTIME_NODE_REGISTRY_PROPS_H
#include <stdint.h>
#include <stdbool.h>
#include "kry_bounds.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
typedef enum NodeTypeFlag {
NodeTypeFlagInsertable = 1,
NodeTypeFlagSelectable = 2,
NodeTypeFlagMovable = 4,
NodeTypeFlagResizable = 8,
} NodeTypeFlag;
typedef struct NodeType {
const char* name;
const char* label;
const char* group;
const char* base;
const char* detail;
NodeTypeFlag flags;
} NodeType;
int32_t NodeTypeCount(void);
const NodeType* NodeTypeAt(int32_t index);
const char* NodeTypeName(int32_t index);
const char* NodeTypeLabel(int32_t index);
const char* NodeTypeGroup(int32_t index);
const char* NodeTypeBase(int32_t index);
const char* NodeTypeDetail(int32_t index);
NodeTypeFlag NodeTypeFlagsAt(int32_t index);
int32_t NodeTypeInsertable(int32_t index);
int32_t NodeTypeSnippet(int32_t index, int32_t x, int32_t y, char* dst, int32_t cap);
#endif /* K_RUNTIME_NODE_REGISTRY_PROPS_H */