PDA

View Full Version : Control not accepting parameters



Doctor49152
04-06-2008, 10:05 PM
I have a panel (not Xpanel) with a MINISLIDER_CTL control on it.

ctl[ 2 ] = MINISLIDER_CTL( panf, panel, "slider", 50, 0, 100 );

for some silly reason it will NOT accept the width value. I added INTRO_CTL to display the CTL_W of the control and it defaults to 117 for the width.

Any ideas why? or what I'm doing wrong?

djethernet
04-07-2008, 02:18 AM
I have a panel (not Xpanel) with a MINISLIDER_CTL control on it.

ctl[ 2 ] = MINISLIDER_CTL( panf, panel, "slider", 50, 0, 100 );

for some silly reason it will NOT accept the width value. I added INTRO_CTL to display the CTL_W of the control and it defaults to 117 for the width.

Any ideas why? or what I'm doing wrong?

I figure you mean the edit box width. I tried this in my rig and got similar results, looks like based on the docs, the "free" edit box that comes with the MINISLIDER_CTL is fixed width, If the fixed width of the integer and floating point controls isn't suitable, you can of course use the string controls and do the numeric conversion yourself.

You should be able to use the STR_CTL to make a box that is the correct size for what you need and couple this with a DRAGBUT_CTL, or use the xpanel option. The width looks like it may be there just to be congruent with the SLIDER_CTL control in which width relates to the slider knob width.

Doctor49152
04-07-2008, 02:56 AM
Thanks

I had really hoped it wouldn't come to that :( I find it kind of silly to have a parameter option and not even use it ?!?! You can even change it in the bundled interface builder.

Oh well its not the last panel and xpanel limitation I'm going to find I'm sure.