![]() |
CXTPTabClientWnd Tab Icons |
Post Reply
|
| Author | |
Jayonas
Newbie
Joined: 28 September 2007 Location: United States Status: Offline Points: 12 |
Post Options
Thanks(0)
Quote Reply
Topic: CXTPTabClientWnd Tab IconsPosted: 17 January 2008 at 6:38pm |
|
I'm looking for the best way to customize the icon to display on each tab in a CXTPTabClientWnd. As far as I can tell, the easiest option is to handle the WM_XTP_GETTABICON message in my derivation of CMDIChildWnd. My problem with this is that it only works with HICONs. Is there a way to specify a PNG or other type of bitmap resource to use as the tab's icon rather than an ICON resource?
It looks like I might be able to override CXTPTabClientWnd::CreateWorkspace to provide my own type of workspace, and override the CWorkspace::DrawIcon to draw anything I want. Is that really the best/easiest way to do it, or did I miss something else? I guess I was expecting it to be able to pull an image out of the CXTPImageManager in my CommandBars based on some ID (the resource ID of the CDocTemplate, perhaps), just like the icons in the ribbon and status bar and docking panes and everywhere else. |
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 18 January 2008 at 2:10am |
|
Yeap, CXTPTabClientWnd::CWorkspace::DrawIcon is method you need override.
|
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
Post Reply
|
|
|
Tweet
|
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |