[IButton,???,"Toggles visibility for selected subtool", [IShowActions,0] [IConfig,2022] [VarSet,selectedST,[SubToolGetActiveIndex]] [VarSet,st,[SubToolGetStatus,selectedST]] [VarSet,tmpFdr,[SubToolGetFolderIndex,0]] [If,[Val,tmpFdr]==0,//visible - turn off [If,[Val,st]&0x02 == 0x02,//visible folder [If,[Val,st]&0x01 == 0x01,//visible - turn off [SubToolSetStatus,selectedST,st-0x01] ,//else turn on [SubToolSetStatus,selectedST,st+0x01] ] ,//else turn on folder [SubToolSetStatus,selectedST,st+0x02] [VarSet,st,[SubToolGetStatus,0]] [If,[Val,st]&0x01 == 0x01,//visible OK ,//else turn on [SubToolSetStatus,selectedST,st+0x01] ] ] ,//else no folder [If,[Val,st]&0x01 == 0x01,//visible - turn off [SubToolSetStatus,selectedST,st-0x01] ,//else turn on [SubToolSetStatus,selectedST,st+0x01] ] ] ,,1/2,,,]