【发布时间】:2018-09-01 11:13:59
【问题描述】:
mintty 2.8.5 for MSYS2 使用 Shift+Insert 进行粘贴。但在我的笔记本电脑上,Insert btn 与 Delete 键不匹配,也就是说,要实际粘贴 mintty,我需要按 Shift+Fn+Delete,这很烦人。
是否可以将薄荷粘贴操作绑定到 Shift+Delete?
【问题讨论】:
mintty 2.8.5 for MSYS2 使用 Shift+Insert 进行粘贴。但在我的笔记本电脑上,Insert btn 与 Delete 键不匹配,也就是说,要实际粘贴 mintty,我需要按 Shift+Fn+Delete,这很烦人。
是否可以将薄荷粘贴操作绑定到 Shift+Delete?
【问题讨论】:
我能想到的唯一方法是使用类似于
的补丁diff --git a/src/wininput.c b/src/wininput.c
index 20f2f3e..0f2958c 100644
--- a/src/wininput.c
+++ b/src/wininput.c
@@ -2033,7 +2033,8 @@ win_key_down(WPARAM wp, LPARAM lp)
goto skip_shortcuts;
// Copy&paste
- if (cfg.clip_shortcuts && key == VK_INSERT && mods && !alt) {
+ if (cfg.clip_shortcuts && (key == VK_INSERT || key == VK_DELETE)
+ && mods && !alt) {
if (ctrl)
term_copy();
if (shift)
我已经用 https://github.com/mintty/mintty 的 rev 0e65eec39 对其进行了测试
【讨论】: