Print Page | Close Window

Group bar icon size

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Task Panel
Forum Description: Topics Related to Codejock Task Panel
URL: http://forum.codejock.com/forum_posts.asp?TID=7282
Printed Date: 09 May 2024 at 12:36pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Group bar icon size
Posted By: dasbrid
Subject: Group bar icon size
Date Posted: 01 June 2007 at 5:54am
We are using task panel control with VC++ 6.0.
Two questions/problems with changing the size of our group bar icons.

Our standard icon size is 45(width) x 24(height), we would like to use these on items and group bars.

The SetGroupIconSize(x,y) method does not work as documented (or like the SetIconSize method). The two parameters are listed as x and y. however, when we set the FIRST parameter this changes the HEIGHT of the icon. Changing the SECOND paramter has no effect - the group bar icon is always displayed with width 16.

Any ideas?

-------------
Dave Asbridge
Software Developer
7layersolutions.net



Replies:
Posted By: Oleg
Date Posted: 01 June 2007 at 8:31am
Hi,
Need sample to check how you set icons/how you call method etc.
 


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


Posted By: dasbrid
Date Posted: 01 June 2007 at 9:46am

Thanks Oleg,

First thing we do is call the following once
 
SetGroupIconSize(24, 45)
 
Then for an item that is a group bar (e.g Devices),  we do the following:-
 
hComponentIcon = LoadIcon(IDI_RC_DEVICES_EXE); 
if (hComponentIcon != NULL)
{
  nImageIndex = AddImage((long)hComponentIcon);
  CTaskPanelGroup group = GetGroups().Add(nGroupID, "Devcies");  
  group.SetIconIndex(imageIndex);
  group = AddGroup(strText, nImageIndex);      
}

 


-------------
Dave Asbridge
Software Developer
7layersolutions.net


Posted By: Oleg
Date Posted: 01 June 2007 at 11:55am
Hi,
 
I sure problem in LoadIcon you use. By Default it loads 32*32 icons. Create Bitmap and load it Icons collection.


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


Posted By: dasbrid
Date Posted: 04 June 2007 at 10:20am
Hi Oleg,
 
This issue has now been resolved.
 
You were right in that the problem was with the LoadIcon we usd. We replaced it with LoadImage and all is well with the world again.
 
Thanks once again for pointing me in the right direction


-------------
Dave Asbridge
Software Developer
7layersolutions.net



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