https://github.com/lynn/extract-apple-keyboard-layouts
Python script for parsing and converting AppleKeyboardLayouts-L.dat
https://github.com/lynn/extract-apple-keyboard-layouts
Last synced: 2 months ago
JSON representation
Python script for parsing and converting AppleKeyboardLayouts-L.dat
- Host: GitHub
- URL: https://github.com/lynn/extract-apple-keyboard-layouts
- Owner: lynn
- License: mit
- Created: 2025-02-11T15:47:50.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2025-02-11T15:56:28.000Z (3 months ago)
- Last Synced: 2025-02-28T22:41:05.640Z (3 months ago)
- Language: Python
- Size: 6.84 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# extract-apple-keyboard-layouts
Python script for parsing and converting the default Mac keyboard layouts file at `/System/Library/Keyboard Layouts/AppleKeyboardLayouts.bundle/Contents/Resources/AppleKeyboardLayouts-L.dat`.Usage: `python3 extract.py` (there are no dependencies, you'll just need Python 3.8+).
References:
* ["Format of AppleKeyboardLayouts-L.dat" on the ukelele-users group](https://groups.google.com/g/ukelele-users/c/xRo9BwPeFpg)
* [uchr specification](https://leopard-adc.pepas.com/documentation/Carbon/Reference/Unicode_Utilities_Ref/uu_app_uchr/uu_app_uchr.html)For now it just parses the file and checks that I can play with the contents of `Dvorak`. The idea is to convert them from binary to XML `.keylayout` files that can be easily edited (by hand or with [Ukelele](https://software.sil.org/ukelele/)) and added to `~/Library/Keyboard Layouts`.