After `make clean`, which deletes unicode-data/, `make test` failed because
nothing fetched the conformance files unless src/unicode-data.h had to be
regenerated. Add a test-data target that runs download-test-data.sh, which
only downloads missing files, and make the test, ctest, coverage, and
test-elixir targets depend on it.
Add download-test-data.bat as the Windows counterpart and the same test-data
target and dependencies to Makefile.nmake. Check out batch files with CRLF
line endings, since cmd.exe can miss labels in LF-only batch files.
Signed-off-by: Francesco Bigiarini <francesco.bigiarini@gmail.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
* Add character data to the Elixir package
Mojibake.Char exposes the character data of single codepoints: names,
categories, combining and bidi classes, decomposition types, numeric
values, simple case mappings, blocks, scripts and Script_Extensions,
East Asian width, emoji properties, and every stored binary and
enumerated property. Mojibake.Script, Block, Plane, and Property
describe their values, Mojibake.Emoji classifies emoji sequences, and
Mojibake.Hangul composes and decomposes syllables.
Values are atoms made from the long UCD names. The tables that map the
C enums to atoms are generated by make generate into
src/elixir/lib/mojibake/unicode_data.ex, and the NIF statically checks
the hand-written bidi and emoji enums it maps.
The new UCD tests compare the results with UnicodeData.txt, Blocks.txt,
the property files, and PropertyValueAliases.txt.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Francesco Bigiarini <francesco.bigiarini@gmail.com>
* Use the C records for private-use and surrogate codepoints
Now that mjb_codepoint_info returns records for surrogates and
private-use codepoints (#188), drop the Elixir category fallback for
them, and check every First/Last range of UnicodeData.txt. The Unicode
18 Tangut, Jurchen, and Seal ranges that the C library does not cover
yet are skipped.
Download the UCD files that the Elixir character-data tests read in
download-test-data.sh, so they run in CI.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Francesco Bigiarini <francesco.bigiarini@gmail.com>
* Check the Unicode 18 ideograph ranges in the Elixir UCD tests
mjb_codepoint_info now returns records for the full Tangut ranges and
the Jurchen and Seal ranges (#189), so the UnicodeData.txt range test
no longer skips them.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Francesco Bigiarini <francesco.bigiarini@gmail.com>
---------
Signed-off-by: Francesco Bigiarini <francesco.bigiarini@gmail.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
* Modify the amalgamation scripts to copy the new version to macOS app folder
* Add locale switch in the case view
* Add detailed comment
* Add quick check to normalize view
* Rename Characters view to Text Inspector
* Fix boxes size
* Fix: change "scalars" name to "codepoints"