我如何以编程方式操纵Windows 7屏幕键盘osk:移动,调整大小,删除标题栏/标题 [英] How can i programmatically manipulate the Windows 7 on-screen keyboard osk: Move, Resize, Remove Titlebar/Caption

查看:173
本文介绍了我如何以编程方式操纵Windows 7屏幕键盘osk:移动,调整大小,删除标题栏/标题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用WPF应用程序,我想以始终在那里"的方式在屏幕上显示内置的Windows 7键盘.所以我想:

I'm working on a WPF app where i want to display the built-in windows 7 onscreen keyboard in a 'always there' manner. So i want to:

  1. 将其移动到特定位置

  1. Move it to a particular location

将其设置为一定的宽度和高度

Set it to a certain width and height

删除标题/标题栏,使用户无法四处移动或关闭它

Remove the caption/titlebar so the user can't move it around or close it

删除该功能以调整其大小(或对此问题进行任何其他用户调整).

Remove that abilty to resize it (or any other user adjustments for that matter).

我已经尝试了所有典型的API函数(MoveWindow,SetWindowPos,SetWindowLong等),但是它拒绝执行任何操作.目前,代码可与所有其他进程和应用程序配合使用(例如Internet Explorer和命令提示符);几乎就像api调用不适用于osk一样,或者它已被锁定".我想念什么?预先感谢.

I've tried all the typical API functions (MoveWindow, SetWindowPos, SetWindowLong, etc...) but it refuses to do anything. Code currently works with all other processes and apps (such as internet explorer and the command prompt); it's almost as if the api calls don't apply to the osk, or that it's 'locked'. What am i missing? Thanks in advance.

推荐答案

我使用Spy ++进行了检查,并且屏幕键盘使用了一种名为"DirectUIHWND"的东西.您可能希望研究DirectUIHWND API.

I checked with Spy++ and the On-Screen Keyboard uses something called "DirectUIHWND". You may wish to look into DirectUIHWND APIs.

可能有用的链接:

此外,有人警告DirectUI 未记录.

In addition, some people have warned that DirectUI is undocumented.

这篇关于我如何以编程方式操纵Windows 7屏幕键盘osk:移动,调整大小,删除标题栏/标题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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