A cloud input method that uses Google Input Tools as engine for macOS.
-
Install Xcode 12.5.0+.
-
Clone and build the project.
git clone https://github.com/lennylxx/google-input-tools-macos
cd google-input-tools-macos
./build.sh
The output will be
~/Library/Input\ Methods/GoogleInputTools.app
-
Open
System Preferences->Keyboard->Input Sources, click+to add a new input method, chooseChinese, Simplified->Google Input Tools. -
If you want to remove it, simply run below command.
rm -rf ~/Library/Input\ Methods/GoogleInputTools.app
rm -rf ~/Library/Input\ Methods/GoogleInputTools.swiftmodule
- Basic input handling logic
-
Spacekey to commit current highlighted candidate -
Returnkey to ignore candidate and commit input string - Number keys (
1-9) to select candidate and commit - Continue to show new candidates after partial matched candidate is selected and committed
-
Backspacekey to remove last composing letter -
Esckey to cancel composing -
-/↑and=/↓keys to page up and page down candidate list respectively - Arrow keys
←/→to switch between highlighted candidate
-
- Chinese/English mode toggle (
Shiftkey) - System UI
- Basic custom UI
- Numbered candidates
- Highlight current selected candidate
- Group candidates into multiple pages, each page with at most
9candidates - Page up and page down
- Draggable candidate window
- Advanced custom UI
- Compose string displayed in candidate window (orange, separate from candidates)
- Padded highlight box on selected candidate with rounded corners
- Display tokenized input string and candidates
- Settings for font name, font size, color, etc.
- Skin display
- Skin manager
- Cloud engine
- Cancel previous unnecessary web requests on new keystroke to speed up
- In-memory LRU cache with SQLite persistence for candidate results
- Frequency-based smart re-ranking of candidates (configurable)
- Offline fallback: serve cached candidates when network is unavailable
- Predictive prefetch: pre-warm cache based on typing history
- Visual indicator (☁️) when candidates are fetched from the network
- Preferences menu (Input scheme, UI mode, font size, page size, smart rerank)
- Input tool switching, such as Pinyin, Shuangpin, Wubi, etc.
- Fullwidth form of punctuation in Chinese mode
- Allow to use HTTP/SOCKS proxy with optional authentication
