Print Page | Close Window

controls in a ribbon bar

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=11889
Printed Date: 17 June 2024 at 5:22am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: controls in a ribbon bar
Posted By: Osiris
Subject: controls in a ribbon bar
Date Posted: 19 August 2008 at 11:07am
Hi all,

if I put two edit controls into a ribbon bar group then they are displayed on top of each other like intended. But the width of the edit controls is not the same - They are both aligned to the right side of the 'column' and reach to the right end of the controls label (see picture)



I tryed to use CXTPControlEdit::SetWidth() and    CXTPControlEdit::SetLabelWidth() but that doesn't seem to have the right effect. I'm afraid that there is no solution to this because in the sample application of the Xtreme Toolkit Pro this problem is 'fixed' by adding some spaces to the end of the shorter label string.
But I've seen a sample picture in a forum entry with correct aligned edit controls - so maybe it is possible.

Another thing I was wondering about is if it would be possible to 'break' the strict column orientation for the ribbon controls. I like to have to button controls below the edit controls like in this picture:




If it is not possible: could one put a whole dialog (resource with own controls) into a ribbon group?

Thanks in advance
Stefan







Replies:
Posted By: Oleg
Date Posted: 19 August 2008 at 3:45pm

Hi,

 
You can try add CXTPControlLabel for captions  instead captions of Edit...


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


Posted By: tobi
Date Posted: 19 August 2008 at 6:09pm
Hi Oleg,

how can I do this with the ActiveX CommandBars ?


Posted By: Oleg
Date Posted: 20 August 2008 at 2:16am
Hi,
 
Same - add xtpControlLabel with captions.


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


Posted By: Marco1
Date Posted: 24 August 2008 at 10:51am
Oleg, can you plese be a little more precisely on that one.

If I add a CXTPControlLabel before a CXTPControlEdit, the EditControl is always in a new line under the ControlLabel but never right of it.

So, this doesn't work:

pControl = pGroup->Add(xtpControlLabel, 0);
pControl->SetCaption(_T("Find"));
pControl->SetStyle(xtpButtonCaption);
pControl->SetWidth(180);

CXTPControlEdit* pControlEdit = (CXTPControlEdit*)pGroup->Add(xtpControlEdit, ID_BUTTON__FIND);
pControlEdit->SetWidth(200);

How do I get both in onle line as seen in the second picture above?


Thanx, Marco



Posted By: Marco1
Date Posted: 12 September 2008 at 12:08pm
As much as I hate bumps, problem is still open.
Can someone provide a short snippet to get the aligned edit controls as on the picture?!


Posted By: Osiris
Date Posted: 17 September 2008 at 3:22am
Hi Marco,

use pControlEdit->SetFlags(xtpFlagWrapRow);





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