Print Page | Close Window

background image in Skinned tab control

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Skin Framework
Forum Description: Topics Related to Codejock Skin Framework
URL: http://forum.codejock.com/forum_posts.asp?TID=7611
Printed Date: 22 November 2024 at 6:23pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: background image in Skinned tab control
Posted By: adrien
Subject: background image in Skinned tab control
Date Posted: 17 July 2007 at 3:25am
hi
 
how can one get the background image to show through for a tab control?
 
We have our own tab control class that we can add panes to using a dialog resource.  Since it uses code based on CDialog to build the pane, it shows the background colour of the pane as being the button face color.
 
however, due to background images, this means we get a weird border round the pane, and it doesn't show the correct colour.  I've tried overriding OnCtlColor, but since the background is an image, I'm picking I can't get an HBRUSH to return.
 
I also tried making the dialog resource transparent, but that didn't do anything (possibly MFC ignores it?).
 
Also, in some schemas (like the iTunes one), the metrics are different (i.e iTunes adds a 5px top line to the background image).  Is there an API we can use to get these offsets so we can offset the pane?
 
Or am I wasting my time with our own tab control class, and I should just use a CodeJock one?  We've got a lot of legacy code to port if I can't use our old one...
 
Anyone done this before?

Adrien



Replies:
Posted By: Oleg
Date Posted: 17 July 2007 at 9:47am

Hello,

to understand what do  you do send to mailto:support@codejock.com - support@codejock.com sample project with screenshot what do you want to see.


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


Posted By: adrien
Date Posted: 19 July 2007 at 6:41pm
Hi
 
I changed over one of our dialogs from our own tab control dialog class to a CPropertySheet and CPropertyPage implementation.
 
now it shows the proper background image (i.e. brushed metal in iTunes skin) rather than the button face color of a normal dialog background.
 
 


Posted By: Deadly_B
Date Posted: 12 May 2009 at 11:36am
I wish it were that simple in C#.  We had to write some extra code for our app to http://blog.villainousmind.com/2009/04/fix-backcolor-for-tabcontrol-in-net.html - show the background .



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