您可以通过在 Sublime Text 上创建一个宏及其键绑定来替换默认行为Ctrl+C
key:
包/用户/SelectLineNoEOL.sublime-macro
[
{ "command": "move_to", "args": { "to": "hardbol" } },
{ "command": "move_to", "args": { "to": "eol", "extend": true } },
{ "command": "copy" },
]
默认.sublime-keymap
{ "keys": ["ctrl+c"], "command": "run_macro_file",
"args": {"file": "res://Packages/User/SelectLineNoEOL.sublime-macro"},
"context":
[
{
"key": "selection_empty", "operator": "equal",
"operand": true, "match_all": false,
},
],
},
我想我已经看到另一个带有插件的线程可以做到这一点,但我找不到它。
相关主题:
-
论坛#14576 https://forum.sublimetext.com/t/how-to-disable-selecting-newline-on-triple-click/14576如何禁用三次单击时选择换行符?
-
论坛#14933 https://forum.sublimetext.com/t/st3-copy-blank-line-using-yy-p-vi-paste-one-extra-line/14933[ST3]使用 yy;p (Vi) 复制空行,再粘贴一行