Default README: 简体中文
Other languages: English | Français | Deutsch | 日本語
LockInput is a lightweight macOS menu bar app that locks the current input method and helps prevent accidental input source switching while writing, coding, or moving between apps.
- Locks the current input method and switches back if another source becomes active
- Allows Caps Lock to temporarily switch to an ABC/ASCII layout while a Chinese-style input method is locked
- Runs in the menu bar without a Dock icon
- Left-click opens the input source panel; right-click opens quick actions
- Supports English, 简体中文, Français, Deutsch, and 日本語
- Supports launch at login on macOS 13.0 or later
- macOS 12.0 Monterey or later
- Launch at login requires macOS 13.0 or later
Install from GitHub Releases:
- Open the Releases page.
- Download the latest
LockInput-1.0.dmg. - Open the DMG and drag
lockinput.apptoApplications. - Launch LockInput from
Applications.
The current release is not Apple-notarized. If macOS blocks the first launch, allow it in System Settings > Privacy & Security, or Control-click the app and choose Open.
- Left-click the menu bar lock icon to open the main panel
- Right-click the menu bar lock icon to open the quick actions menu
- Click an input method in the list to switch to it and lock it
- Use the Lock / Unlock button to lock the current source or release the lock
- When a Chinese-style input method is locked, press Caps Lock to temporarily use an ABC/ASCII layout; switching back to the locked source keeps the lock active
- Change the interface language from the language menu at the bottom
- Enable Launch at Login to start the app automatically after login on macOS 13.0+
git clone https://github.com/bigccc/inputlock.git
cd inputlock
open lockinput.xcodeprojSelect the lockinput scheme in Xcode, then run the app.
If xcodebuild points to Command Line Tools, switch to full Xcode:
sudo xcode-select -s /Applications/Xcode.app/Contents/DeveloperBuild the Release app:
xcodebuild -project lockinput.xcodeproj \
-scheme lockinput \
-configuration Release \
-derivedDataPath build \
clean buildCreate the DMG:
./scripts/create-dmg.shThe generated file is:
LockInput-1.0.dmg
lockinput/
├── lockinputApp.swift # App entry point and menu bar setup
├── ContentView.swift # Main panel UI
├── InputMethodManager.swift # Input source discovery, switching, and lock enforcement
├── InputSourceLockState.swift # Lock state model
├── LanguageManager.swift # Runtime language switching
├── Info.plist # App metadata
├── Assets.xcassets/ # Icons and assets
└── Resources/
├── en.lproj/ # English
├── zh-Hans.lproj/ # Simplified Chinese
├── fr.lproj/ # French
├── de.lproj/ # German
└── ja.lproj/ # Japanese
To add a language:
- Create a new
.lprojfolder underlockinput/Resources/. - Copy an existing
Localizable.stringsfile and translate it. - Add the language code to
knownRegionsinlockinput.xcodeproj/project.pbxproj. - Add the language to the
AppLanguageenum inLanguageManager.swift.
This repository does not currently include a separate LICENSE file.