Keep and restore fcitx state for each buffer separately when
leaving/re-entering insert mode or search mode. Like always typing
English in normal mode, but Chinese in insert mode.
D-Bus only works with the same user so this won't work with
sudo vim. See the fcitx5-server branch for an
experimental implementation that supports sudo vim.
By default, it use python3 and D-Bus to toggle IME state. If you set
g:fcitx5_remote to the executable path of
fcitx5-remoteBEFORE loading the plugin,
it will use fcitx5-remote instead of python and D-Bus. In
this case, python3 support is optional.
Usually fcitx5-remote mode is way faster to start up
since Python script need quite some time for the initial load if you
don't use any other plugins that load Python. The Python version will be
faster while switching.
Base requirements:
fcitx 5
Requirements for Python mode (g:fcitx5_remote is not
set):
Vim with Python 3 compiled in
The python-dbus package
Requirements for fcitx5-remote mode
(g:fcitx5_remote is set):
fcitx5-remote
If you are using fcitx5-rime (which has its own state),
let g:fcitx5_rime = 1 in your .vimrc.
The FcitxCurrentIM() function can be used to get current
IM's name.
If you use Vim in terminal, to avoid the Esc delay, please set
'ttimeoutlen' to 100 or some other value. And check
screen's maptimeout or tmux's escape-time
option if you use it too.
This repository is currently unmaintained. For the time being (as of
August, 2023), it is recommended to use one of the following plugin
managers instead:
lazy.nvim: Most
stable and maintained plugin manager for Nvim.
pckr.nvim:
Spiritual successor of packer.nvim. Functional but not as stable as
lazy.nvim.
Create a file <template_name>.template inside a
folder which is searched by the plugin( see
below), e.g. if you want to create a template file for a c++ main
file you can name it cppmain.template or
cppm.template
Sub 图片版式转换() Dim n '图片个数 Dim oShape As Variant OnErrorResumeNext For n = 1To ActiveDocument.Shapes.Count 'Shapes类型图片 ActiveDocument.Shapes(1).ConvertToInlineShape Next n EndSub