Print Page | Close Window

RIBBON Query: to support 24*22 size bitmap

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Command Bars
Forum Description: Topics Related to Codejock Command Bars
URL: http://forum.codejock.com/forum_posts.asp?TID=17630
Printed Date: 02 December 2024 at 11:29pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: RIBBON Query: to support 24*22 size bitmap
Posted By: archies
Subject: RIBBON Query: to support 24*22 size bitmap
Date Posted: 02 December 2010 at 6:34am
Hi All;

This query is regarding the RIBBON behaviour with images.
by default RIBBON takes
16*16 bmp for small image
32*32 bmp for large image

i need to use the 24*22 (width*height) bmp image in RIBBON , it gets blurred .

I can't made all my image to 32*32.
Please tell me the procedure , by which i add the image (24*22) size without blur

thnx in advance



Replies:
Posted By: archies
Date Posted: 03 December 2010 at 1:48am
Hi ;
Let me make my problem short and more understandable.

In my application:-
CXTPRibbon having CXTPControl button.
CXTPControl having style "xtpButtonIconAndCaptionBelow".
It will make the CXTPControl icon as (32*32) size and put the Caption below this.

*I am using (24*22) bitmap : hence they stretch in 32*32 size and get blurred.
How can i use (24*22) bitmap ? Either its possible ?

SetIconSize - not working.
XTPPaintmanager and XTPImagemanager can't help me out.

thnx


Posted By: Daelen
Date Posted: 09 December 2010 at 1:59pm
Hi there. I experienced the problem just like yours except for my icons have a size of 36x36. This helped me:
    CommandBars.Options.SetIconSize True, 36, 36
    CommandBars.Options.LargeIcons = True

And in yours case:
    CommandBars.Options.SetIconSize True, 24, 22




Posted By: archies
Date Posted: 15 December 2010 at 1:10am
Hi Oleg;

Please don't keep me waiting for so Long.....

Please see me above issue....

How can we Attach the 24*22 size Bitmap in the "xtpConrolButton" ?

Is it possible or not ?

Thnx in Advance


Posted By: archies
Date Posted: 27 January 2011 at 12:32am
Hi;
If we set the Style "xtpButtonIconAndCaptionBelow" in CXTPControl object.
pXtpControl->SetStyle(xtpButtonIconAndCaptionBelow);

Now , Big Button have been displayed .
That Button having 32*32 icon + Text below.

I have both the Big Button and the Normal button in a Ribbon.

hence to place the 24*22 icon on the big button i use :

pXtpControl->SetIconSize(CSize(24,22));

But this can't make the icon as 24*22 i=on Big button.



Posted By: archies
Date Posted: 16 March 2011 at 8:39am
Hi oleg;

I am adding "CXTPControlPopup" control with control type "xtpControlSplitButtonPopup".

Then i set the XTPButtonStyle as "xtpButtonIconAndCaptionBelow"

Then i add icon on Button :
pControl->GetImageManager()->SetIcon(hIcon,cmdIDBtn);

The icon of size 32*32 coming correct .
But if i wish to show the 24*22 sized icon , it get blurred/poor quality.

How can we set the XTPCommandBar --> so that large icon size will be 24*22 and small icon size will be 16*15.

Please suggest any solution.


Posted By: Oleg
Date Posted: 16 March 2011 at 12:00pm
Sorry all icons should be same size.  You can open in editor and add transparent borders around to make it 32*32.

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


Posted By: archies
Date Posted: 17 March 2011 at 12:36am
Thanx Oleg
Now it works.



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