From ef80d93367a07e0878bdf78f7b0c2f53647b8ce5 Mon Sep 17 00:00:00 2001 From: will wade Date: Sat, 29 Aug 2026 15:43:56 +0000 Subject: [PATCH 1/3] chore: bump DasherCore to v0.2.14 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 150 alphabets train on real Tatoeba sentences (was 48) — 56 new corpora imported from WorldAlphabets v0.1.1 (CC-BY 2.0 FR) - Training weight: 74MB -> 23MB (400KB cap) — 51MB off the APK - Alphabet index records training_available - Script-aware corpus retargeting + injection into undeclared WA alphabets (54 now declare their Tatoeba corpus) Signed-off-by: will wade --- third_party/DasherCore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/third_party/DasherCore b/third_party/DasherCore index 901e4d8..10ebe6a 160000 --- a/third_party/DasherCore +++ b/third_party/DasherCore @@ -1 +1 @@ -Subproject commit 901e4d815171665f04c4fd6c60192ce299f0f54f +Subproject commit 10ebe6aa2f247e9e03ec6940c72b7e153d388ff1 From bc2631381737eb98f849b1babfea5fce8e6dd005 Mon Sep 17 00:00:00 2001 From: will wade Date: Sat, 29 Aug 2026 19:51:15 +0100 Subject: [PATCH 2/3] chore: bump DasherCore to v0.2.14 complete (all training corpora) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Submodule at ba7a634a — the full v0.2.14 including the 56 Tatoeba corpora that were initially eaten by .gitignore (DasherCore #74). Signed-off-by: will wade --- third_party/DasherCore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/third_party/DasherCore b/third_party/DasherCore index 10ebe6a..ba7a634 160000 --- a/third_party/DasherCore +++ b/third_party/DasherCore @@ -1 +1 @@ -Subproject commit 10ebe6aa2f247e9e03ec6940c72b7e153d388ff1 +Subproject commit ba7a634a8d054ba933238faaa0146554b1fd7e0b From 46c844f165c4d2131f969e6f9873a66386b677eb Mon Sep 17 00:00:00 2001 From: will wade Date: Sat, 29 Aug 2026 20:27:46 +0100 Subject: [PATCH 3/3] fix: Settings crash (invalid UTF-8) + alphabet picker showing one entry MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Two bugs discovered on-device/emulator: 1. Settings crash: the LP_UNIFORM parameter description contained the multiplication sign as a single Latin-1 byte (0xD7) instead of UTF-8 (0xC3 97) — 'Uniform probability weight (×1000)' — a leftover mojibake 'fix' that traded wrong bytes for broken encoding. JNI's NewStringUTF validates Modified UTF-8 and aborts the process the moment nativeGetParameterInfo returns the string. Fixed in DasherCore's Parameters.cpp (also fixed upstream). 2. Alphabet picker showing one entry: the engine was queried (getAlphabetNames, locale-follow) before the canvas laid out, and set_screen_size was gated on canvas width > 0 — so Realize() (which builds the 474-entry name index) never ran before the first query. The picker got GetPermittedValues' single-item fallback (the current alphabet name). DasherEngine.create() now calls nativeSetScreenSize(800, 600) as a provisional size so the engine realizes immediately; the canvas corrects it when it lays out. Verified on emulator: Settings opens without crashing; alphabet picker lists 475 alphabets (Abc through Afrikaans and beyond). Signed-off-by: will wade --- app/src/main/java/at/dasher/android/DasherEngine.kt | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/at/dasher/android/DasherEngine.kt b/app/src/main/java/at/dasher/android/DasherEngine.kt index cc083ff..96bde8c 100644 --- a/app/src/main/java/at/dasher/android/DasherEngine.kt +++ b/app/src/main/java/at/dasher/android/DasherEngine.kt @@ -662,7 +662,16 @@ class DasherEngine( Log.e(TAG, "nativeCreate returned 0 — dataDir=$dataDir") return null } - return DasherEngine(handle, userDir, frameConsumer) + val eng = DasherEngine(handle, userDir, frameConsumer) + // Realize the engine immediately with a provisional screen size. + // Realize() builds the alphabet name index (474 entries) and loads + // the selected alphabet — without this, queries made before the + // canvas lays out (getAlphabetNames, locale-follow, etc.) see an + // unrealized engine with an empty index: the alphabet picker + // showed one entry and locale-follow had nothing to match against. + // The canvas corrects the size when it actually lays out. + NativeBridge.nativeSetScreenSize(handle, 800, 600) + return eng } } }