delphi 修改代码补全的快捷键(由Ctrl+Space 改为 Ctrl + alt + Space)(通过修改OpenTool生效)
2016-07-06 23:58
633 查看
delphi 的IDE快捷键与输入法切换键中突,以往的解决方法是下载一个ImeTool修改 windows 系统的快捷键
在 xp win7 都好使,但在win 10经常是修改完后,重启又失效了。
本方法采用 Open Tools API 编写是一个组件。安装方法:
菜单-->Component -->install Component 然后选择此本单元,然后就瞎折腾吧。就好了。
源码下载
http://www.cnblogs.com/lackey/p/5373761.html
在 xp win7 都好使,但在win 10经常是修改完后,重启又失效了。
本方法采用 Open Tools API 编写是一个组件。安装方法:
菜单-->Component -->install Component 然后选择此本单元,然后就瞎折腾吧。就好了。
源码下载
unit EagleBufferList; interface procedure Register; implementation uses Windows, Classes, SysUtils, Menus, ToolsAPI, Controls; type TBufferList = class(TNotifierObject, IUnknown, IOTANotifier, IOTAKeyboardBinding) function GetBindingType: TBindingType; function GetDisplayName: string; function GetName: string; //指定快捷键 procedure BindKeyboard(const BindingServices: IOTAKeyBindingServices); protected procedure CodeCompletion(const Context: IOTAKeyContext; KeyCode: TShortcut; var BindingResult: TKeyBindingResult); end; resourcestring sBufferList = 'Eagle''s Buffer List'; // register this key binding procedure Register; begin (BorlandIDEServices as IOTAKeyBoardServices).AddKeyboardBinding(TBufferList.Create); end; { TBufferList } // the code to bind key procedure TBufferList.BindKeyboard(const BindingServices: IOTAKeyBindingServices); begin BindingServices.AddKeyBinding([ShortCut(Ord('P'), [ssShift, ssCtrl, ssAlt])], CodeCompletion, Pointer(csCodeList or csManual)); BindingServices.AddKeyBinding([ShortCut(Ord('O'), [ssShift, ssCtrl, ssAlt])], CodeCompletion, Pointer(csParamList or csManual)); BindingServices.AddKeyBinding([ShortCut(Ord(' '), [ssCtrl, ssAlt])], CodeCompletion, Pointer(csCodeList or csParamList or csManual)); { 1,2句是原作者写的 3句是我加的 把代码补完快捷键 替换为 ctrl + alt + space } end; // do code completion procedure TBufferList.CodeCompletion(const Context: IOTAKeyContext; KeyCode: TShortcut; var BindingResult: TKeyBindingResult); begin (Context.EditBuffer.TopView as IOTAEditActions).CodeCompletion(Byte(Context.Context)); BindingResult := krHandled; end; function TBufferList.GetBindingType: TBindingType; begin Result := btPartial; end; function TBufferList.GetDisplayName: string; begin Result := sBufferList; end; function TBufferList.GetName: string; begin Result := 'EagleKing.BufferList'; // do not localize end; end.
http://www.cnblogs.com/lackey/p/5373761.html
相关文章推荐
- delphi 把多个线程的请求阻塞到另一个线程 TElegantThread
- delphi 属性 参数 新注释
- Delphi调用Java类
- Delphi 设置时间格式
- Delphi Berlin 10.1 for 小米平板2 (Win 10) 电子罗盘测试
- Delphi通过ICMP检测与远程主机连接
- 关于android UDP 客户端与delphi UDP服务端通讯中文乱码问题
- delphi query阻塞执行 长时间执行sql的解决办法
- Delphi与字符编码(实战篇)(MultiByteToWideChar会返回转换后的宽字符串长度)
- delphi sql中加like 写法
- 该如何让自己从一个c++程序员变成一个delphi程序员
- delphi设计浮动窗口
- delphi安装 Tclientsocket, Tserversocket控件
- 在Delphi中使用键盘勾子获取键盘输入(译--5月7日)
- Delphi制作软键盘
- Delphi格式化输出函数(1): Format
- delphi字符串操作函数一览
- 常用的BCB&Delphi 函数
- 一个功能增强的Delphi TListView组件
- Delphi异常处理try except语句和try finally语句用法以及区别