keaising/im-select.nvim

github github
editing-support
star 13
stars
alert-circle 0
open issues
users 1
subscribers
git-branch 2
forks
CREATED

2022-07-27

UPDATED

18 days ago


im-select.nvim

Switch Input Method automatically depends on Neovim's edit mode.

The old vim plugins (such as im-select) works weird on my Macbook, so I just create this im-select in pure lua for Neovim, it works charmly!

Current version only works for Neovim on macOS and Windows.

Linux/wsl support is welcome!

1. Install binary

Please install execute binary im-select first!

Download URL: im-select

2. Install plugin

Packer

use 'keaising/im-select.nvim'

Plug

Plug 'keaising/im-select.nvim'

3. Config

Simple setup with default value works well enough:

require('im_select').setup()

If you want to change some settings:

require('im_select').setup {
    -- IM will be set to `default_im_select` in `normal` mode(`EnterVim` or `InsertLeave`)
    -- For Windows, default: "1003", aka: English US Keyboard
    -- You can use `im-select` in cli to get the IM name of you preferred
    default_im_select  = "com.apple.keylayout.ABC",

    -- Set to 1 if you don't want restore IM status when `InsertEnter`
    disable_auto_restore = 0,
}