mirror of
https://github.com/ghostty-org/ghostty.git
synced 2026-09-14 18:01:58 +00:00
`send key` only works for control keys like `enter` currently; this adds (fixes) the support for other keys listed as available. Found by @paaloeye in #13180 The core of this fix is relying on `UCKeyTranslate` to get the corresponding character and code point from a key code using `KeyboardLayout.character(for:modifiers:)`. ScriptKeyEventCommand now respects `macos-option-as-alt`, and attach `text`, `unshifted_codepoint` and `consumed_mods` under the same condition as a manual input events like in `performKeyEquivalent` and `localEventKeyDown`. ## AI Disclosure Claude did the heavy lifting, I reviewed and rephrased some of the comments it generated. And ofc reviewed and tested myself.