Comments (7)
Actually, even if I open sublime-text by clicking on the icon, I still have this problem of deleting words in the wrong place...
So could you kindly show me the configuration in your sublime-text.desktop please? @Xiang-DangDang
from sublime-text-imfix.
我的配置文件没有改动过,下载安装后,除了安装你提供的 sublime-text-imfix 插件,没有过任何改动,我使用的操作系统为 基于 debian 的 deepin,以下是我的 sublime-text 配置文件,目前使用最新版本的sublime-text,这个问题在以前版本也出现
[Desktop Entry]
Version=1.0
Type=Application
Name=Sublime Text
GenericName=Text Editor
Comment=Sophisticated text editor for code, markup and prose
#Exec=/opt/sublime_text/sublime_text %F
Exec=/usr/bin/subl %F
Terminal=false
MimeType=text/plain;
Icon=sublime-text
Categories=TextEditor;Development;
StartupNotify=true
Actions=Window;Document;
StartupWMClass=Sublime_text
[Desktop Action Window]
Name=New Window
#Exec=/opt/sublime_text/sublime_text -n
Exec=/usr/bin/subl -n
OnlyShowIn=Unity;
[Desktop Action Document]
Name=New File
#Exec=/opt/sublime_text/sublime_text --command new_file
Exec=/usr/bin/subl --command new_file
OnlyShowIn=Unity;
from sublime-text-imfix.
你好!
首先我不是作者,我也是同样遇到这个问题的使用者。
不过我的状况更糟一些,因为我即便双击图标打开 sublime 也无法正常使用退格键。另外,在我的系统里,直接使用作者提供的 .so 文件是无法在 sublime 里成功使用 fcitx 的——每次切换到 fcitx ,都会立即跳回为英文输入法,完全无法使用。还得先修改源代码,将其中关于 fcitx 的部分删掉,只保留关于 xim 的部分,再重新编译为 .so 文件,这时才能在 sublime 里用 fcitx 。(我自己开了个 issue 描述这个奇怪的问题,不过作者回复说无法重现,见 #50 )不过这样带来的好处是, ibus 倒能用了。。。
我的系统是:
- Ubuntu 14.04 + i3wm (其实在 xfce4/mate 桌面下也试过,都不行)
- fcitx 4.2.8.5
- Sublime Text 3 Build 3143
这样看来,还是只能滚回继续用 vim 了。。但好喜欢 sublime 的新配色 Mariana 啊 T_T 。。
from sublime-text-imfix.
Now I have come up with a way to partially solve this problem of deleting with backspace. Although it has some shortcomings, it could at least provide a fairly acceptive experience of typing Chinese characters with fcitx.
- Open Preferences -> Key Bindings in sublime.
- Copy all the contents from the left column (Default) to the right column (User).
- Comment this line :
//{ "keys": ["backspace"], "command": "left_delete" },
in the right column (User). (It is Line 19 in my file.) - Open a terminal, and go into the configuration folder of sublime, like
~/.config/sublime-text-3/Packages/
. - Make a new folder "Default" in the folder "Packages":
mkdir Default
. - Copy the user keymap file to this "Default" folder:
cp ./User/Default\ \(Linux\).sublime-keymap ./Default
Now backspace will behave correctly - it will delete words in the input box of fcitx rather than in sublime.
The theory is that although the default .sublime-keymap is read-only, the .sublime-keymap file in the Default folder will override the original default one, and thus we can modify it. Therefore, with the line of backspace key in the default keymap file deleted, sublime loses the control of backspace, and thus fcitx could get control of that key when in need.
But this method is not perfect. It has a side effect - the backspace key can never be used in sublime any more. To work around, we can just use shift+backspace which has the same function with backspace, or try to use del key, or even vim mode. : )
Reference:
https://forum.sublimetext.com/t/input-method-support/5446/30 (See stevenfrog's post)
PS.
If you are using some plugins concerning applying (new) keymap, also remember to comment/delete the lines with backspace key involved, or the plugins will ask sublime to back again take control of backspace and never give the control of that key to fcitx. Like as for the package ActuralVim, we need to comment // { "keys": ["backspace"], "args": {"key": "<bs>"}, "context": [{ "key": "setting.actual_intercept", "operand": true }], "command": "actual_keypress" },
(Line 23 in my file) in the keymap configuration file of ActualVim, which is ~/.config/sublime-text-3/Packages/ActualVim/Default.sublime-keymap
.
PSS.
In order not to cause some other bugs in ActualVim, like the wrong behavior of insert after deleting with shift+backspace - the words are inserted in the position before deleting rather than after it, we should change "backspace" to "shift+backspace" in the line mentioned above in the keymap configuration file of ActualVim, rather than simply comment/delete that line.
from sublime-text-imfix.
我也同样遇到了这个问题。不过,我不是通过subl命令打开,而是,直接点击sublime桌面图标打开。
from sublime-text-imfix.
在我这里只有新创建的文件被保存的时候才会发生这种问题。cmd/ctrl+s保存完接着编辑的时候所有的窗口都会出现delete键删除不正常的问题。
from sublime-text-imfix.
在我这里只有新创建的文件被保存的时候才会发生这种问题。cmd/ctrl+s保存完接着编辑的时候所有的窗口都会出现delete键删除不正常的问题。
我也是这样,现在我明白什么时候才会触发了。
from sublime-text-imfix.
Related Issues (20)
- Not work in Ubuntu 17.10 HOT 1
- 使用Aur或archlinuxcn源安装的sublime的ArchLinux用户
- 输入法备选框还是不跟随。 HOT 11
- 成功解决问题 HOT 3
- 无法做到输入法backspace,按回格(backspace)键输入法中的拼音不回格(backspace)而是汉字被删除 HOT 14
- 菜单栏锁定后打开不能使用输入法 HOT 1
- 关于从sublime里面创建文件然后保存文件后的拼音无法正常输入
- 18.04 無法適用 HOT 5
- 打开2个subl窗口,只能在最新的subl输入中文 HOT 4
- 新建的编译Fortran受影响
- 这行命令是什么意思?
- cannot be preloaded HOT 2
- deepin 最新系统无法输入中文
- 可以输入中文了,但是无法打开文件所在目录
- This fix stop working with Sublime Text GTK3 build 3181+ HOT 3
- It doesn't work on Linux Mint 19.1
- 通过桌面图标和subl命令打开可以输入中文,但把图标固定到task bar之后打开就无法输入中文了,很奇怪... HOT 1
- ubuntu18.04刚按着操作,然后...subl启动不了了 HOT 2
- 3.2.1 build3207之后的版本都默认支持中文输入注释。 HOT 1
- 3.2.2 Build 3211无法使用,安装这个包后用命令无法打开sublime,点击图标可以打开
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sublime-text-imfix.