diff options
author | Thomas Voss <mail@thomasvoss.com> | 2024-04-12 00:16:49 +0200 |
---|---|---|
committer | Thomas Voss <mail@thomasvoss.com> | 2024-04-12 00:16:49 +0200 |
commit | fc0a8e668aef4360b6a8ed780dd15c2e80fc70f9 (patch) | |
tree | 93a895b2ece4720c9f5e79fc5751a1ec3f01cefd /include/unicode | |
parent | eaa205db54705622580b77aef57f6bdbd2fa5bf2 (diff) |
Add uprop_get_uc()
Diffstat (limited to 'include/unicode')
-rw-r--r-- | include/unicode/prop.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/include/unicode/prop.h b/include/unicode/prop.h index ebbc817..f58118d 100644 --- a/include/unicode/prop.h +++ b/include/unicode/prop.h @@ -2,10 +2,22 @@ #define MLIB_UNICODE_PROP_H #include <inttypes.h> +#include <stddef.h> #include "__rune.h" #include "__u8view.h" +struct rview { + const rune *p; + size_t len; +}; + +struct ucctx { + bool az_or_tr : 1; /* Azeri or Turkish */ + bool cap_eszett : 1; /* Use capital eszett */ + bool lt_after_i : 1; /* After āiā in Lithuanian */ +}; + enum uprop_bpt { BPT_N, /* None */ BPT_C, /* Close */ @@ -156,6 +168,7 @@ enum uprop_nt { [[__mlib_uprop_attrs]] rune uprop_get_slc(rune); [[__mlib_uprop_attrs]] rune uprop_get_stc(rune); [[__mlib_uprop_attrs]] rune uprop_get_suc(rune); +[[__mlib_uprop_attrs]] struct rview uprop_get_uc(rune, struct ucctx); [[__mlib_uprop_attrs]] struct u8view uprop_get_na1(rune); [[__mlib_uprop_attrs]] struct u8view uprop_get_na(rune); |