如何在Windows窗体中更改Radiobutton的颜色 [英] How Do I Change The Color Of The Radiobutton In Windows Form
本文介绍了如何在Windows窗体中更改Radiobutton的颜色的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
大家好,
任何人都可以告诉我如何更改无线电按钮的颜色,即每当检查到一个小蓝点时,我想要这个蓝点它是红色还是绿色。
提前谢谢。
解决方案
MSDN有一个你做的所有化妆品变化都很好的例子(尽管不是所有的变化) http://msdn.microsoft.com/en-us/library/cc296247(v = vs.95).aspx
还有更多定义:MSDN的RadioButton类。希望这有帮助。 (您正在查看的属性是RadioButton.Checked 属性
< blockquote>一个单选按钮,按钮和文本是一个控件。如果你想改变它的外观,你可以覆盖 OnPaint
,但你需要绘制这两个部分。 br />
参见此示例: http://devblog.antongochev.net/2008/07/09/create-custom-ui-appearance-for-winforms-radiobutton-part-3/ [< a href =http://devblog.antongochev.net/2008/07/09/create-custom-ui-appearance-for-winforms-radiobutton-part-3/target =_ blanktitle =New Window > ^ ]
-KR
Hi all,
Can anybody tell me how to change the color of the radiobutton i.e, whenever it is checked a small blue dot appears this blue dot i want it to be either red or green.
Thanks in advance.
解决方案
Hi, MSDN has a nice example with all the cosmetic changes you may make (altough not all of them at) http://msdn.microsoft.com/en-us/library/cc296247(v=vs.95).aspx
There is also much more definitions at: RadioButton Class from MSDN. Hope this help. (The property you are looking at isRadioButton.Checked Property
A radio button, button and text together, is one control. If you want to change its appearance, you can overrideOnPaint
, but you need to draw both parts.
See this example : http://devblog.antongochev.net/2008/07/09/create-custom-ui-appearance-for-winforms-radiobutton-part-3/[^]
-KR
这篇关于如何在Windows窗体中更改Radiobutton的颜色的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文