Commit graph

8 commits

Author SHA1 Message Date
Marc Durdin
ba46d2127d chore(core): address review comments 2024-01-19 09:50:00 +07:00
Marc Durdin
3878394787 chore(core): remove todo comment 2024-01-18 08:53:55 +07:00
Marc Durdin
425ebe36b0 feat(core): synchronize app_context for non-normalizing keyboardprocessors
Fixes #10421.
2024-01-18 08:52:59 +07:00
Marc Durdin
4ab47ea435 chore(core): further debug assertions for actions_normalize 2024-01-18 08:39:53 +07:00
Marc Durdin
823120b0c4 chore(core): simplify input assumptions for actions_normalize
Per discussion in #10422, we can assume that input cached_context is
always NFD. However input actions->output may not start at a
normalization boundary, so we still need to backtrack to a normalization
boundary in order to get our NFC output. But cached_context never need
change.

This makes no change to the algorithm, but tweaks some of the unit tests
to adhere to this input assumption.

Note: we could consider adding a debug assertion that cached_context is
NFD.
2024-01-18 08:25:15 +07:00
Marc Durdin
40f0839a4a chore(core): remove bogus test_color.h inclusion 2024-01-17 11:03:42 +07:00
Marc Durdin
e6096a267c feat(core): action output normalization
Fixes #9999.

Note TODO items:
- [ ] Renormalize cached_context across action boundary. Blocked by #10369.
- [ ] Add extra tests for surrogate pairs
- [ ] Move set_context_from_string into helper module
- [ ] if we don't apply normalization, we still need to fixup the
      app_context, to keep it coherent with cached_context (or at least
      we need to verify that app_context is never used in this
      situation)
2024-01-17 10:41:00 +07:00
Marc Durdin
e39affe93b feat(core): infrastructure for normalization of output
Relates to #9999.

Establishes functions, unit test sources, normalization entry point and
an effectively no-op unit test for normalization support.
2024-01-16 13:46:46 +07:00