[与本项目无关] [功能请求] 写注释的时候自动切换输入法
Ran-Xing opened this issue · comments
星冉 commented
- On Mac computers, switching input methods defaults to command + space
- In different countries and languages, use your own country's language to write code comments. You can use [idea]'s 「translation」 when converting to English.
So is there an existing plugin that can do this?
My idea is to use idea's sdk to detect the automatic switching of input methods when users enter code comment symbols, which is very friendly to workers with poor English
So, what should I do?
星冉 commented
thanks very much
余腾靖 commented
用中文再描述一遍,没看太懂你要干嘛
星冉 commented
谢谢哈
星冉 commented
你是为数不多的高级开发呀,看你贡献代码量第一
余腾靖 commented
思路其实是监听输入了 # 再去修改输入法:
- vscode 监听输入 #,可以监听 editor 的事件
- 修改输入法,试试这个库:https://github.com/octalmage/robotjs
星冉 commented
@tjx666 这个恐怕不行,但是思路我有了,只是不知道有没有idea开放的sdk专门用来检测制定字符,因为idea不一定是写java,也可以写rust,也可以写bash,前提是得获取当前用户编辑文件的类型属性判断该检测哪种字符 ,#还是 //