octalmage / robotjs

Node.js Desktop Automation.
http://robotjs.io
MIT License
12.26k stars 937 forks source link

Fix createStringForKey segmentation fault on Mac OS for non-Latin languages #704

Open barbarian23 opened 2 years ago

barbarian23 commented 2 years ago

Screen Shot 2022-01-13 at 15 58 18

Segmantation Fault occurs if it is non-latin input source on MacOS. I fixed this issue by changing from

TISCopyCurrentASCIICapableKeyboardInputSource

to

TISCopyCurrentKeyboardLayoutInputSource

in createStringForKey function. Tested with 2-set Korean, 3-set Korean and Simple Telex

Refer to this link https://discussions.apple.com/thread/250732490#251392420022

jugglinmike commented 2 years ago

This project appears to be unmaintained, see https://github.com/octalmage/robotjs/pull/622