如何处理VSIX中的键盘事件? [英] How to handle Keyboard events in VSIX?

查看:62
本文介绍了如何处理VSIX中的键盘事件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在VSIX项目上工作,需要检测Enter键 OnKeyUp 事件.如何在文字装饰项目中实现此目的?当有人按下键以在编辑器中更改行时,我需要检测该事件.

I am working on VSIX project where I need to detect Enter key OnKeyUp event. How can I implement this in a Text Adornment project? I Need to detect the event when someone press key for changing the line in the editor.

推荐答案

我在 KeyProcessor 用于处理键盘事件的类.我们可以从此示例中引用.

I got the solution in this thread of mine. We can use KeyProcessor class for keyboard event handling. We can refer from this sample.

这篇关于如何处理VSIX中的键盘事件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆