Print Page | Close Window

Checkbox in Ribbon

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=4010
Printed Date: 15 May 2024 at 9:24pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Checkbox in Ribbon
Posted By: ABuenger
Subject: Checkbox in Ribbon
Date Posted: 15 April 2006 at 2:11pm

I would like to display a checkbox in a ribbon group. The following code works except that I can't check the checkbox and I get no notification when I click the checkbox.

 

CButton *pButton = new CButton ();
pButton->Create (_T("Caption"), BS_CHECKBOX, CRect(0,0,100,20), this, ID_TEST);

CXTPControlCustom *pControl = CXTPControlCustom::CreateControlCustom(pButton);

pGroup->Add(pControl, ID_TEST);




Replies:
Posted By: Oleg
Date Posted: 18 April 2006 at 10:45am

Hello,

Guess you need BS_AUTOCHECKBOX style



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


Posted By: ABuenger
Date Posted: 18 April 2006 at 2:48pm

Originally posted by oleg oleg wrote:

Guess you need BS_AUTOCHECKBOX style

Tried that too, I even got the checkbox working but the background of the checkbox has the wrong color. I've tried to catch the WM_ERASEBKGND message but no success.

It would be nice if the following line would work

pRibbonGroup->Add (xtpControlCheckBox, ID_TEST);

P.S.: If the CButton has a valid command id ("ID_TEST") rather than 0 the system checkbox is drawn and then the XTP themed checkbox everytime the MFC is in idle state and calls the update command handlers, so if you move the mouse you have a flickering checkbox.

 



Posted By: ABuenger
Date Posted: 26 April 2006 at 6:34am

Could you please provide a sample with a checkbox on the ribbon?

Thanks

 



Posted By: ABuenger
Date Posted: 08 May 2006 at 11:16am

?



Posted By: ABuenger
Date Posted: 09 May 2006 at 10:17am

I guess I have to wait for the "next release"?

 



Posted By: Oleg
Date Posted: 09 May 2006 at 10:20am

Hi,

Sorry too much sample requests last week... I preparing new custom CXTPControl for next release, but will attach it here when it will be ready.



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


Posted By: Oleg
Date Posted: 09 May 2006 at 4:40pm

Hello

ok, we added xtpControlCheckBox, but unfortunatelly this class changed too much sources (each PaintManager has own implementation of check box area)

I afraid you must wait next release.



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


Posted By: ABuenger
Date Posted: 09 May 2006 at 5:12pm
Originally posted by oleg oleg wrote:

Hello

ok, we added xtpControlCheckBox, but unfortunatelly this class changed too much sources (each PaintManager has own implementation of check box area)

I afraid you must wait next release.

Thanks oleg, any idea when the next release will be available?

P.S.: It would be nice if ON_COMMAND / ON_UPDATE_COMMAND_UI works for the checkbox on the Ribbon because it would then be a drop in replacement for check menu items.

Thanks again, Andre



Posted By: Oleg
Date Posted: 10 May 2006 at 8:46am

Hello,

Hard to say abou next release... May be in 3 - 4 weeks.

of course, it support ON_COMMAND / ON_UPDATE_COMMAND_UI.

Thanks for patient :)



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



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