更改选中标记或复选框的颜色 [英] Changing color of checkmark or box of checkbox

查看:81
本文介绍了更改选中标记或复选框的颜色的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,

我想更改复选框的选中标记的颜色或复选框本身的背景颜色.因此,我不想更改控件背景的颜色(我发现了几篇关于使用OnEraseBkgnd和OnCtlColor的文章),我想更改选中标记周围的白色.有没有一种方法可以做到而又不必自己绘制完整的控件?

亲切的问候
Marcus

Hello together,

I''d like to change the color of either the checkmark of a checkbox or the background color of the box itself. So, I don''t want to change the color of the control''s background (I found several articles on that using OnEraseBkgnd and OnCtlColor), I''d rather like to change the white color around the checkmark. Is there a way how I can do that without having to draw the complete control on my own?

Kind regards
Marcus

推荐答案

使用位图资源可以轻松地自己绘制它-每个状态一个位图.

问候
Espen Harlinn
Drawing it yourself can be done easily using bitmap resources - one bitmap for each state.

Regards
Espen Harlinn


这篇关于更改选中标记或复选框的颜色的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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