User avatar
By deadalvs
#253448
hello !

is it possible to script a checkbox with an expression ?

i need a very small window that shows via three checkboxes if grid/vertex/curve snap is currently active...

thanks for any input.

:P
User avatar
By deadalvs
#255319

scriptJob -e snapModeChanged d_updateSnapWindow;

if (`window -exists "SnapWindow"` == 1){deleteUI "SnapWindow";}
//WindowPref -remove SnapWindow;
window -title "SnapWindow" -mnb 1 -mxb 1 -wh 300 550 -s 1 SnapWindow;
columnLayout -adjustableColumn 0;
columnLayout;
checkBox -l "GridSnap" -value 0 -en 0 GridSnapBox;
checkBox -l "CurveSnap" -value 0 -en 0 CurveSnapBox;
checkBox -l "VertexSnap" -value 0 -en 0 VertexSnapBox;
setParent ..;
setParent ..;
showWindow SnapWindow;



global proc d_updateSnapWindow(){

if (`snapMode -q -grid` == 0){
checkBox -e -v 0 GridSnapBox;
}
if (`snapMode -q -grid` == 1){
checkBox -e -v 1 GridSnapBox;
}

if (`snapMode -q -curve` == 0){
checkBox -e -v 0 CurveSnapBox;
}
if (`snapMode -q -curve` == 1){
checkBox -e -v 1 CurveSnapBox;
}

if (`snapMode -q -point` == 0){
checkBox -e -v 0 VertexSnapBox;
}
if (`snapMode -q -point` == 1){
checkBox -e -v 1 VertexSnapBox;
}
// end
}

after a lot of years doing arch-viz... almost 20 a[…]

render engines and Maxwell

Funny, I think, that when I check CG sites they ar[…]

Hey, I guess maxwell is not going to be updates a[…]

Help with swimming pool water

Hi Choo Chee. Thanks for posting. I have used re[…]