Mel Script Checker Box
Hi People
I've just started to get into mel and have written a script that helps with your lights. What I need to do is is put that little checker icon on the texture navigation box but I'm banging my head on the keyboard at the moment on how to write it. I've had a look at other scripts but I'm none the wiser at present. Can anyone help me. If they can and succeed I'll send them a copy of it when its done. Many thanx!! |
texture navigation box???
So you want a button with an icon instead of a text label? If yes then you could use the symbolButton command. Basically you use it like a normal button but with the -image flag you assign an image or icon to the button. |
Mel Script
1 Attachment(s)
I'm a bit confuuuuused as always.I've attached an image so you know what I mean. Thanx again
|
With what command did you create those controls?
|
Hi KB
Really appreciate this; attrFieldSliderGrp -min(-1) -max 10 -at ($current + ".intensity"); text " "; columnLayout; setParent; attrColorSliderGrp -at ($current + ".color"); |
Hi Jango,
have you solved the problem? regards Strarup |
MelScript
Unfortunately not, can u help?
|
1 Attachment(s)
Hi Jango,
I can try... but I need some more info... what's the purpose of the function/button is it e.g. something like the code hereunder or more something like the attached image? this is an example from the Maya Docs "iconTextButton.html"... -------------------------------------------------------------- string $window = `window`; columnLayout -adjustableColumn true; iconTextButton -style "textOnly" -image1 "sphere.xpm" -label "sphere"; iconTextButton -style "iconOnly" -image1 "spotlight.xpm" -label "spotlight"; iconTextButton -style "iconAndTextHorizontal" -image1 "cone.xpm" -label "cone"; iconTextButton -style "iconAndTextVertical" -image1 "cube.xpm" -label "cube"; showWindow $window; --------------------------------------------------------------- regards Strarup |
Mel Script
Hi Strarup
Thanx for getting back to me. Its the top checker box that I need, basically for navigating to the materials, texture nodes etc. Its to finish the my script really then its ready for use. I dont want it being incomplete or 'naked' if you know what I mean. |
1 Attachment(s)
Hi Jango,
oki doki... :) you can e.g. try this... create a light e.g. a Directional Light... and then execute the follwing code... then you should get a window as the one in the attached picture... hope it helps you... :) //------------------------------------------------------------------- //modify color and intensity for the selected light string $lightnameA[] = `ls -lt`; window -title "Test"; columnLayout; for ($lightname in $lightnameA) { attrColorSliderGrp -attribute ($lightname +".color"); attrFieldSliderGrp -attribute ($lightname + ".intensity") - min -1 -max 10; } setParent ..; showWindow; //------------------------------------------------------------------- regards Strarup |
All times are GMT. The time now is 11:23 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Simply Maya 2018