keyman
keyman copied to clipboard
spec(common): KMX+ binary format supporting LDML
Introduction
Document an optimized binary format for use by the process_event #5015 and other consumers of LDML data. It will be written into the KMX binary file.
Goals
- new section is 64-bit aligned
- new section and header uses 64-bit offsets
implementation
- kmx_file.h - version16, kmx+ file header
- kmx+ optimized binary format
- in-memory structures for LDML keyboard
other
- json or xml streamers (dev use)
- binary streamer <-> into .kmx file (prod)
- use bson?
Moved
This spec is now in-repo at https://github.com/keymanapp/keyman/blob/feature-ldml/core/src/ldml/C7043_ldml.md or eventually https://github.com/keymanapp/keyman/blob/master/core/src/ldml/C7043_ldml.md
@mcdurdin simplifying starting assumptions if you want:
- could skip deduplicating strings
- could always use
extend=1in keys (i.e. always burn a string for each key)
Changes:
- sections on 128 bit (0x10 byte) boundary for convenience
- added 4 byte reserved/padding on keys table so keys start on 128 bit boundary, and also for strs table
Binary format done, minor tweaks but validated and useful.