Print Page | Close Window

Rectangular Tab Icons

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Docking Pane
Forum Description: Topics Related to Codejock Docking Pane
URL: http://forum.codejock.com/forum_posts.asp?TID=21681
Printed Date: 04 May 2024 at 9:36am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Rectangular Tab Icons
Posted By: GARC
Subject: Rectangular Tab Icons
Date Posted: 29 May 2013 at 10:16am
Hello.

I am trying to set rectangular tab icons for my docking panes. I have created an image list of 5 images of 72x36 pixels each. This is the piece of code I am using to assign these images to the tab icons inside my OnCreate function:

m_PaneManager.GetPaintManager()->GetTabPaintManager()->m_szIcon = CSize(72, 36);
CXTPImageManager* icons_manager = m_PaneManager.GetImageManager();
icons_manager->SetIcons(m_tabs_image_list, nIDIcons, _countof(nIDIcons), CSize(72, 36), xtpImageNormal);


Once executed, I notice that the tabs are higher than desired as shown in the following picture:


As you can see, despite the images are shown correctly, and although the size of the icons has been set to CSize(72,36) as shown in the code, it seems to be forced to show a square 72x72 icon size, producing those undesireble margins up and down each image.
How can I get rid of those margins and maintain the height of the tabs in 36 pixels?

Thanks in advance.
Alex.




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