Skip to content

Improve IME handling - #11

Merged
oligo merged 4 commits into
mainfrom
ime
Jul 3, 2026
Merged

Improve IME handling#11
oligo merged 4 commits into
mainfrom
ime

Conversation

@oligo

@oligo oligo commented Jul 3, 2026

Copy link
Copy Markdown
Owner

As the release of Gio v0.10.1, we can handle IME composition event. This release added composition event handling,
and also fixed some text buffer issues related to redo/undo.

  • bump gio to the latest version. This version fixed the long-existing windows IME composition issue.
  • handling CompositionEvent in editor to detect composition state. The composition text input is batched in the text buffer level so we can undo them as a whole. But there is still a issue that the first character is left when undoing the last inputs, because of EditEvent fires before CompositionEvent.
  • draw composition underline(dash or line pattern)
  • Fixed piecetable unGroupOp.
  • Optimized insert merge policy of piecetable, so space characters and character class transitions starts a new piece, not merging with the previous piece. This makes the undo more controllable and safe.

oligo added 4 commits July 1, 2026 14:14
- bump gio to the latest version. This version fixed the long-existing windows IME composition issue.
- handling CompositionEvent in editor to detect composition state.
- draw composition underline(dash or line pattern)
- optimize insert merge policy:
  1. multiple characters input won't be merged.
  2. unicode space characters are not merged.
  3. character class transitions: transitions between normal chars and punctuations/symbols.
 This prevent different chars from being undo as a unit, and similar chars can be combines
 and undo as a unit.

- fix UngroupOp nil pointer issue.
- fix lastInsertPiece set to nil issue after replace.
…ndo/redo, so user

don't have to do multiple undo to clear the input.
@oligo
oligo merged commit b4c2046 into main Jul 3, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant