Labelled Edit-Controls in RibbonBar aligned ? |
Post Reply |
Author | |
cpehonk
Groupie Joined: 27 April 2008 Location: Germany Status: Offline Points: 22 |
Post Options
Thanks(0)
Posted: 19 October 2008 at 10:56am |
Hi !
It's me again ...
How can I align CXTPControlEdit controls in a RibbonBar group with different labels ? I would like to have the edit controls itself with the same width und left aligned. Like in this example:
But this is achieved by adding numerous spaces at the end of a label to align them. There must be a more elegant solution !
I tried "SetLabelWidth()" but I did not get it to work.
Any hints ?
Greetings,
Chris
|
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Hi,
afraid there is no more elegant solution :-(
We will add something.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
cpehonk
Groupie Joined: 27 April 2008 Location: Germany Status: Offline Points: 22 |
Post Options
Thanks(0)
|
Thanks, Oleg.
Please, keep me informed about what you'll add.
|
|
DavidH
Groupie Joined: 24 March 2007 Status: Offline Points: 59 |
Post Options
Thanks(0)
|
I'm having the same problem.
Is there any solution yet? David. |
|
DavidH
Groupie Joined: 24 March 2007 Status: Offline Points: 59 |
Post Options
Thanks(0)
|
Dear CodeJock team,
I'm trying to work out how to fix this but it would have been easier if more of the CXTPControlEdit methods were virtual. I do this by inheriting from CXTPControlEdit, and because of the lack of virtual methods, CXTPRibbonTheme. I really don't want to change your source code, as it will make any upgrade later very tricky. Anyway, I'm only halfway done, and feeling a bit uneasy about it. Are you intending to fix this in an upcoming release? If so, I'd really like to know as it will save me a mountain of work. Also, I'm sure that your solution will be better. Best regards from a satisfied customer, David. |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Hi,
yes, we going to fix it, do you have suggestion how to make it more smart. SetLabelWidth is not really good solution, because it depends on selected font.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
DavidH
Groupie Joined: 24 March 2007 Status: Offline Points: 59 |
Post Options
Thanks(0)
|
Hi Oleg,
First, thanks for replying. The easiest way in my case would probably be to be able to set the minimum width for the 'edit' area of a CXTPControlEdit. Then, if there are multiple CXTPControlEdits in a column, CodeJock should find the greatest minimum width, and the greatest labelWidth. Add the two to get the overall column width. All this maybe under a 'xtpLineUp' flag for the items in a column? I'd really like this MinimumEditWidth, as I have multiple language versions, so the label text varies wildly in length. Alternatively, just a 'xtpLineUp' flag would be OK, where CodeJock simply uses the max labelWidth of the labels in the column. Of course, I have not thought through all the details with RtL languages etc. That might spoil the fun a bit. Thanks again, David. P.S. Currently, the SetLabelWidth is somewhat misleading, as it's always called by the framework itself just before drawing. So using this method has no effect at all for the library user. While you're at it, you might want to standardize on terminology in the code for 'Label' and 'Caption' for edit controls. |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
ok, thanks, checking what to do best :) |
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
Satyen
Groupie Joined: 22 December 2008 Location: India Status: Offline Points: 16 |
Post Options
Thanks(0)
|
Hello Oleg,
I am also facing similar issue wherein two edit boxes and a spinner control (all placed one below another and having labels) are messed up. There alignment is wrong for different locales. Further, the label is overriding control in front of it. Regards,
Satyen.
|
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |