C# 更改全局鼠标光标
我有一个带有透明度键颜色的表单,我正在其中进行全局鼠标挂钩以进行右键单击。
直到一切正常,但由于表单是透明的,因此鼠标光标会根据表单后面的内容而变化。
有什么办法可以改变全局鼠标光标吗?
I have a form with a Transparency-key color, where I'm doing a global mouse hook for the right click.
Until there everything is okay, but since the form is transparent, the mouse cursor is changing according to what is behind the form.
Is there any way to change the global mouse cursor?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
是的,这就是透明度的运作方式。不仅针对用户的眼睛,还针对鼠标从左眼看到的内容。必须以这种方式工作,如果没有,主要用户会感到困惑,没有选择更改它。
解决方法是显示桌面的假版本。屏幕截图。这正是广受欢迎的 Windows 截图工具的作用。示例代码位于此线程中。
Yup, that's how transparency works. Not just to the eye of the user, also to what the mouse sees from its left eye. Has to work that way, major user confusion if it didn't, no option to change it.
The workaround is to show a fake version of the desktop. A screen shot. Just what the ever popular Windows Snipping Tool does. Sample code is in this thread.