dropdownlist question
Forgive the newbie question but I can find no examples and should be EZ for readers here.
We're writing a script to take perceptual computing input to drive interactive models. UI needs lots of dropdownlist selectors where the actual selected item is simply X, Y, or Z (very short string). We'd like to put both the list label and the drop down selector all on a single line.
Standard dropdownlist setup puts the label above the list. That uses up two lines and you end up with very wide pull down that has very short list members.
Is there any magic syntax for setting up a dropdownlist where the label and the actual pull down list both sit on the same line?
Thanks!
Comments
...
Use single lable control for that
bga
dropdownlist
Thank you very much for quick response. That's greatly appreciated.
I should have been more specific. These dropdowns need to work inside a group. It appears that the position pos:[30,5] arguments are not compatible with groups? When those are added, the whole group disappears.
Is there a way to use the same technique within MaxScript groups?
coyote808
...
GroupBox is the answer
bga
...
Also try to use "offset" property of control instead of "pos" property.
It's difficult for me to test any solution because I not see your dialog code.
So try to experiment a bit more. Use MXS help document
bga
dropdownlist
On further experimentation - it's not that position arguments are incompatible with groups. I can add a group around your example dropdowns successfully.
The issue appears to be that I'm not using a createDialog command to build my rollouts. Instead i'm using a series of addrollout commands. Those rollouts are built at the top of the script. At the bottom there is this.
UDP = newRolloutFloater "User Defined Properties" 250 715 50 50
addrollout utilities UDP rolledup: false
addrollout actionSet UDP rolledup: true
addrollout pickableObject UDP rolledup: true
addrollout bitmapTextLabel UDP rolledUp: true
addrollout geometricTextLabel UDP rolledUp: true
addrollout cameraActions UDP rolledUp: true
addrollout shaderActions UDP rolledup: true
addrollout zSortActions UDP rolledup: true
addrollout videoInsertActions UDP rolledup: true
addrollout deformationActions UDP rolledup: true
I'm trying to add these formatted dropdownlists to several of the rollouts in the list above.
coyote808
dropdownlist
Thank you very much for your assistance.
I think I've found the problem. The position arguments are working, but they are absolute position values within the rollout (vs. relative to the just previous rollout element). These are big rollouts with lots of detail. The new dropdownlists were appearing at the top. I was looking for them at the bottom. By adding 700 to the Y values in the position arguments, they now appear correctly.
Thanks again for your patience and your help. It's really great to have a resource like this.
Best,
Mike
coyote808
...
My pleasure man.
bga