unicode_props.h (1186B)
1 /* gramunicode_props.h - generated Unicode property table interface. */ 2 #ifndef KIT_GRAM_UNICODE_PROPS_H 3 #define KIT_GRAM_UNICODE_PROPS_H 4 5 #include <kit/core.h> 6 7 #include <stdbool.h> 8 #include <stddef.h> 9 #include <stdint.h> 10 11 typedef struct { 12 uint32_t first; 13 uint32_t last; 14 } KitGramUnicodeRange; 15 16 typedef struct { 17 const KitGramUnicodeRange *ranges; 18 size_t count; 19 } KitGramUnicodeSet; 20 21 typedef enum { 22 KIT_GRAM_UNICODE_PROP_OK, 23 KIT_GRAM_UNICODE_PROP_UNKNOWN_PROPERTY, 24 KIT_GRAM_UNICODE_PROP_UNKNOWN_VALUE, 25 } KitGramUnicodePropStatus; 26 27 KIT_API const char *kit_gram_unicode_props_version(void); 28 29 KIT_API bool kit_gram_unicode_set_contains(const KitGramUnicodeSet *set, uint32_t cp); 30 31 KIT_API KitGramUnicodePropStatus kit_gram_unicode_resolve_property(const char *property, 32 const char *value, 33 KitGramUnicodeSet *out); 34 KIT_API KitGramUnicodePropStatus kit_gram_unicode_resolve_property_spec(const char *spec, 35 KitGramUnicodeSet *out); 36 37 #endif /* KIT_GRAM_UNICODE_PROPS_H */