Print Page | Close Window

CXTPPropertyGridPaintManager background color

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=12876
Printed Date: 23 June 2025 at 11:54am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: CXTPPropertyGridPaintManager background color
Posted By: MacW
Subject: CXTPPropertyGridPaintManager background color
Date Posted: 09 December 2008 at 10:06am
Hi,

when I call ResetContent() on an XTPPropertyGrid, the "grid view" area fill with a white background color.

Even when I call SetCustomColors, and also set the metrix of the CXTPPropertyGridPaintManager instance and the color-related members of the color manager to other colors.

If there is at least one element in the list (property grid) the custom colors are applied.

How do I ensure that the background of the grid is the same when there is no entry in the grid?

The code is very confusing, combining color members in the paint manager, a color metrics structure and even sending WM_CTLCOLORSTATIC to the parent of the grid if the member variable m_bTransparent (???) is set, or the member variable m_clrFace of the paint manager equals GetXtremeColor(COLOR_3DFACE). What do you want to achieve with this.

Useless to say that neither in your code nor in your "documentation" is anything mentioned about this.






Replies:
Posted By: Oleg
Date Posted: 10 December 2008 at 1:34am
Hello,
 
Thanks, we agree this bug.
 
Please make following changes in void CXTPPropertyGridView::OnPaint() replace
 
CWnd::DefWindowProc(WM_PAINT, (WPARAM)buffer.m_hDC, 0);
 
to
 
 if (GetCount())
 {
  CWnd::DefWindowProc(WM_PAINT, (WPARAM)buffer.m_hDC, 0);
 }


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: MacW
Date Posted: 10 December 2008 at 8:39am
Thanks, Oleg!

I will do that.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net