PDA

View Full Version : MEL_UI_Collapse


arunspooja
05-15-2006, 12:04 PM
Good Afternoon friends



I have created a small panel for modeling tools in that, if i collapse the framelayout there is a space between two framelayouts,

but i didnt want that space, i didnt want any space there.



foreg. create any object in maya and go attribute editor and check it out. If you collapse the layout will resize depending on that.

And there will be no space between two frame layouts.



If any one knows kindly reply



Thank you







window -title "MODEL_TOOLS";

//-------mainform-----------

formLayout -w 240 -nd 100 mainform;



//-------curvesform----------

formLayout -p "mainform" -w 170 curvesform;

frameLayout -p "curvesform" -l "EDIT CURVES" -bs "etchedIn" -w 170 -h 90 -cll 1;

rowColumnLayout -nc 2 -cw 1 80 -cw 2 84 -cs 1 2 -cat 2 "both" 2 ;

button -l "Attach Curve*" -c ("AttachCurve");

popupMenu;

menuItem -l "*" -c ("AttachCurveOptions");



button -l "Detach Curve*" -c ("DetachCurve");

popupMenu;

menuItem -l "*" -c ("DetachCurveOptions");



button -l "Cut Curve*" -c ("CutCurve");

popupMenu;

menuItem -l "*" -c ("CutCurveOptions");



button -l "Rev_curve_dir*" -c("ReverseCurve");

popupMenu;

menuItem -l "*" -c("ReverseCurveOptions");



button -l "Rebuild Curve*" -c("RebuildCurve");

popupMenu;

menuItem -l "*" -c("RebuildCurveOptions");



button -l "Rebuild Curve" -c("RebuildCurve");



//----surfaceform----



formLayout -p "mainform" -w 170 surfacesform;

frameLayout -p "surfacesform" -l "SURFACES" -bs "etchedIn" -w 170 -h 68 -cll 1;

rowColumnLayout -nc 2 -cw 1 80 -cw 2 84 -cs 1 2 -cat 2 "both" 2;

button -l "Revolve" -c("Revolve");

popupMenu;

menuItem -l "*" -c("RevolveOptions");



button -l "Loft" -c("Loft");

popupMenu;

menuItem -l "*" -c("LoftOptions");



button -l "Extrude" -c("Extrude");

popupMenu;

menuItem -l "*" -c("ExtrudeOptions");









//----nurbsform------

formLayout -p "mainform" -w 170 nurbsform;

frameLayout -p "nurbsform" -l "EDIT NURBS" -bs "etchedIn" -w 170 -h 90 -cll 1;

rowColumnLayout -nc 2 -cw 1 80 -cw 2 84 -cs 1 2 -cat 2 "both" 2;

button -l "Att_Surfaces*" -c ("AttachSurfaces");

popupMenu;

menuItem -l "*" -c("AttachSurfacesOptions");



button -l "Det_Surfaces*" -c ("DetachSurfaces");

popupMenu;

menuItem -l "*" -c("DetachSurfacesOptions");



button -l "InsertIsoparms*" -c("InsertIsoparms");

popupMenu;

menuItem -l "*" -c("InsertIsoparmsOptions");



button -l ("Rev_surfDir*") -c("ReverseSurfaceDirection");

popupMenu;

menuItem -l "*" -c("ReverseSurfaceDirectionOptions");



button -l ("Rebuild_Surf*") -c("RebuildSurfaces");

popupMenu;

menuItem -l "*" -c("RebuildSurfacesOptions");



button -l ("Sculpt_Surf*") -c("SculptSurfacesTool");

popupMenu;

menuItem -l "*" -c("SculptSurfacesToolOptions");



formLayout -e

-af curvesform "top" 3

-af curvesform "left" 5

-af nurbsform "top" 96

-af nurbsform "left" 5

-af surfacesform "top" 189

-af surfacesform "left" 5

mainform;



showWindow;

goleafsgo
05-15-2006, 02:27 PM
The last chunk of code should look like this...


formLayout -e

-af curvesform "top" 3

-af curvesform "left" 5

-ac nurbsform "top" 5 curvesform

-af nurbsform "left" 5

-ac surfacesform "top" 5 nurbsform

-af surfacesform "left" 5

mainform;


If you look closely, I've change a couple of "-af" flags to "-ac" flags. -ac is -attachControl. So the first set of buttons you have you attach the top to the form but the next two sets you attach to the form above it instead of the main form. This way when one of the collapses the ones that are attached to it move as well.

arunspooja
05-16-2006, 09:22 AM
Thanks for the reply.

Its working fine

CGTalk Moderation
05-16-2006, 09:22 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.