文字框和光标 [英] Textbox and cursor

查看:59
本文介绍了文字框和光标的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

1)如何隐藏文本框的选择而不禁用它.我将其设置为只读,因此不允许更改文本,但我希望它不允许选择,即单击该文本时不应在文本框中显示ibeam光标.

2)我正在做一个项目,其中我选择了一个不同的游标,并且当客户端使用软件时,我希望同一个游标应该在那里.仅当客户端打开应用程序时,它才应该在那儿,否则普通光标就在那儿.

在此先谢谢!!

1) how can i hide selection of the textbox without disabling it. I have set it to read only, so it is not allowing to change the text but I want that it should not allow to select i.e it should not show ibeam cursor in the textbox when clicked in it.

2) I am doing a project in which i have selected a different cursor and i want that the same cursor should be there when the client works with software. it should be there only when the client opens the application otherwise the normal cursor is there.

Thanks in Advance!!!

推荐答案

我认为您将不得不查看诸如selectionchanged之类的事件,并覆盖它们以将选择内容重置为空.
I would think you''re going to have to look at events like selectionchanged and override them to reset the selection to be nothing.


关于您的第二个问题,有些解决方案的范围从复杂 a>处理鼠标光标时.
Regarding your second question, there are solutions that range from simple to complex when dealing with mouse cursors.


这篇关于文字框和光标的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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