为属性表的边框着色 [英] Coloring the border of a property sheet

查看:100
本文介绍了为属性表的边框着色的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,我想在一个彩色对话框中使用3页的属性表.我设法在对话框中创建了一个动态属性表.我还可以更改属性页的颜色.但是我无法更改属性表边框的颜色,它仍然是默认的Windows对话框颜色.谁能帮我给它上色.我不能使用选项卡控件(否则会很容易).请帮我.我还遍历了以下链接,但它对我无效. :( 帮助!-> CPropertySheet出现问题 [ ^ ]

解决方案

最后,我做了它.我可以给属性表的整个区域上色,我使用以下代码实现了它:

 newBrush1 = :: CreateSolidBrush(COLOR);
OldBrush =(HBRUSH):: SetClassLong(GetTabControl()-> GetSafeHwnd(),GCL_HBRBACKGROUND,(LONG)newBrush1); 


要更改选项卡的背景颜色,请覆盖所有者绘图.在对话框编辑器中?


Hi, I want to use a property sheet with 3 pages inside a colored dialog. I managed to create a dynamic property sheet inside the dialog. I could also change the color of the property page. But I cannot change the color of the border of the property sheet and it is still in the default windows dialog color. Could anyone help me to color it. I cannot use tab control(Otherwise it would be easy). Please help me. I also traversed the following link but it didnot work with me. :( Help! --> Problem with CPropertySheet[^]

解决方案

At last I made it. I could color the entire area of the property sheet. I implemented it by using the following code:

newBrush1 = ::CreateSolidBrush(COLOR);
OldBrush = (HBRUSH)::SetClassLong(GetTabControl()->GetSafeHwnd(), GCL_HBRBACKGROUND, (LONG)newBrush1);


To change the background color of the tab, override the owner draw.


Have you tried just changing the border for the page (perhaps to "thin") in the properties when you open the page in the dialog editor?


这篇关于为属性表的边框着色的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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