Sujet : Re: C23 thoughts and opinions
De : ldo (at) *nospam* nz.invalid (Lawrence D'Oliveiro)
Groupes : comp.lang.cDate : 28. May 2024, 03:45:48
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <v33ggr$e0ph$1@dont-email.me>
References : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
User-Agent : Pan/0.158 (Avdiivka; )
On Mon, 27 May 2024 14:03:16 +0100, bart wrote:
On 27/05/2024 03:48, Lawrence D'Oliveiro wrote:
>
Apparently that is not so easy as you seem to think.
Yes, it is as easy as I think. I’ve done this sort of thing, using
suitable build scripts.
Show me.
Here <
https://github.com/ldo/unicode_browser_android> is an old
example, from when I was trying to learn Android programming. It lets
you browse the Unicode code-point database, and do incremental
searches by partial matching on code-point names: e.g. you can type
“right arrow” and see candidate matches such as “U+219B RIGHTWARDS
ARROW WITH STROKE”, “U+219D RIGHTWARDS WAVE ARROW”, “U+21A0 RIGHTWARDS
TWO HEADED ARROW” etc.
In the “util” subdirectory, you will find a Python script called
“get_codes”. This processes a NamesList.txt file as downloaded from
Unicode.org, and encodes the database as a binary blob with a
specially-constructed header to allow quick loading and extraction of
code-point information, including names, categories, related entries
etc. This blob gets built as a “resource file” into the .apk file,
where the Java code can find it.