为所有应用程序设计系统范围的自动完成预测菜单 [英] Designing a system wide autocomplete prediction menu for all applications
本文介绍了为所有应用程序设计系统范围的自动完成预测菜单的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
嗨朋友们,
我正在尝试设计一个系统范围的自动完成菜单,显示用户输入的预测,如何输入。如何实现它......
示例: - 如果我在键盘中键入自动预测菜单应显示为自动,汽车等选项...
我在VC ++中使用Visual Studio进行尝试。
分享你的建议和参考资料请...
谢谢
我的尝试:
我设计了一个包含ListBox的窗口,其中添加了项目...
Hi Friends,
I'm Trying To Design A System Wide Autocomplete Menu Showing Predictions Of The User Input As They Type.How To Implement It...
Example:-If I Type "Auto" In Keyboard The Prediction Menu Should Appear With Options Like Automatic,Automobile,etc...
I'm Trying It In VC++ Using Visual Studio.
Share Me Your Suggestions And References Please...
Thank You
What I have tried:
I Have Designed A Window Containing ListBox With Items Added To It...
推荐答案
你会必须安装全局键盘钩子,跟踪活动窗口以了解何时输入到不同的应用程序或输入控件,并在自动完成时模拟击键。
如何通过简单的网络研究找到这个:
SetWindowsHookEx函数(Windows) [ ^ ]
SendInput功能(Windows) [ ^ ]
但你有没有想过可能的副作用?
这是一个安全风险。您的服务还将在内部捕获并存储用户名和密码。因此我不会使用它;特别是当它提供自动学习功能时,不仅可以临时存储输入的字符串。
You would have to install a global keyboard hook, track the active window to know when input goes to a different application or input control, and simulate key strokes upon auto completition.
How to do that can be found out with a simple web research:
SetWindowsHookEx function (Windows)[^]
SendInput function (Windows)[^]
But have you thought about possible side effects?
It is a security risk. Your service would also catch and store user names and passwords internally. For that reason I would not use it; especially when it provides an auto learning feature which stores entered strings not only temporarily.
这篇关于为所有应用程序设计系统范围的自动完成预测菜单的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文