Sort Column Arrow Color
Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Report Control
Forum Description: Topics Related to Codejock Report Control
URL: http://forum.codejock.com/forum_posts.asp?TID=6600
Printed Date: 15 November 2024 at 4:03pm Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com
Topic: Sort Column Arrow Color
Posted By: Kurisu
Subject: Sort Column Arrow Color
Date Posted: 08 March 2007 at 12:38pm
Hello, just wondering if there was an easy/semi-easy way to draw the arrow in the sort column as a different color..
I noticed the CXTPPaintManager has a Triangle() method..
If this is what I need where would I get the Point coordinates from?
If there is some simple function call or variable somewhere that allows me to change the arrow color that I overlooked.. please tell me
Thanks.
(Just started using XTP... very very nice )
|
Replies:
Posted By: Kurisu
Date Posted: 21 March 2007 at 6:33pm
Posted By: sserge
Date Posted: 22 March 2007 at 5:30pm
Hi,
Sorry, missed your question.
Yes, this arrow is drawn with this method. If you look inside, you'll see that the triangle is drawn using regular user's Windows colors: color variables are initialized from COLOR_3DHIGHLIGHT and COLOR_3DSHADOW. (details there: http://msdn2.microsoft.com/en-us/library/ms724371.aspx - http://msdn2.microsoft.com/en-us/library/ms724371.aspx )
However, same colors are used to draw background and a foreground of the column header. So far, to change only triangle's color, you have to set another color values inside the method:
// Set up pens to use for drawing the triangle CPen penLight(PS_SOLID, 1, m_clrControlLightLight); CPen penShadow(PS_SOLID, 1, m_clrControlDark);
|
Then rebuild the library and your application.
-- WBR, Serge
|
Posted By: Kurisu
Date Posted: 24 March 2007 at 9:23pm
Thanx... much appreciated.
|
|