From b7268373ff61c61f0e904de0aef7e9eab704005b Mon Sep 17 00:00:00 2001 From: Neil Hodgson Date: Sat, 14 Jan 2023 10:03:54 +1100 Subject: Bug [#2374]. Fix character input bug where dotless 'i' and some other extended Latin characters could not be entered. The change also stops SCI_ASSIGNCMDKEY from working with these characters. --- cocoa/ScintillaCocoa.mm | 4 ++++ doc/ScintillaHistory.html | 7 +++++++ 2 files changed, 11 insertions(+) diff --git a/cocoa/ScintillaCocoa.mm b/cocoa/ScintillaCocoa.mm index 0b1693f50..64ea4f874 100644 --- a/cocoa/ScintillaCocoa.mm +++ b/cocoa/ScintillaCocoa.mm @@ -2228,6 +2228,10 @@ bool ScintillaCocoa::KeyboardInput(NSEvent *event) { // Handle each entry individually. Usually we only have one entry anyway. for (size_t i = 0; i < input.length; i++) { const UniChar originalKey = [input characterAtIndex: i]; + // Some Unicode extended Latin characters overlap the Keys enumeration so treat them + // only as and not as command keys. + if (originalKey >= static_cast(Keys::Down) && originalKey <= static_cast(Keys::Menu)) + continue; NSEventModifierFlags modifierFlags = event.modifierFlags; Keys key = KeyTranslate(originalKey, modifierFlags); diff --git a/doc/ScintillaHistory.html b/doc/ScintillaHistory.html index d668a4a2c..4de43355e 100644 --- a/doc/ScintillaHistory.html +++ b/doc/ScintillaHistory.html @@ -589,6 +589,13 @@ Fix SCI_LINESJOIN bug where carriage returns were incorrectly retained. Bug #2372. +
  • + On Cocoa fix character input bug where dotless 'i' and some other extended + Latin characters could not be entered. + The change also stops SCI_ASSIGNCMDKEY from working with these characters + on Cocoa. + Bug #2374. +
  • Release 5.3.2 -- cgit v1.2.3