Clearwin+ allow to update many its controls dynamically. The %il, %fl, %dd and %sl are still among few exceptions.
Here are few examples how things look right now.
If you change the limits, both the %il or slider %sl still
use older hardwired parameters taken at load time.
Attempts to make a workaround opening one more window, change the limits there and push them with window_update@(limits) to change does nothing.
So changing the limits forces the user to close the window and open it again which looks like a pity design defect
SLIDER CODE
real*8 aMin, aMax, aVal
aMin=0
aMax=1
i=winio@('Slide between these two numbers %6rf%6rf&', aMin, aMax)
i=winio@(' %30sl&',aVal, aMin, aMax)
i=winio@(' %rf&',aVal)
i=winio@('%ac[esc]','exit')
end
INTEGER LIMIT CODE
integer iMin, iMax, iVal
iMin=0
iMax=10
i=winio@('Run the wheel up between these two numbers %6rd%6rd&', iMin, iMax)
i=winio@('Run the wheel up %dd%il%6rd%`il&', 1, iMin, iMax, ival)
i=winio@('%ac[esc]','exit')
end
Workaround for INTEGER LIMIT CODE
common iMin, iMax, iVal
integer cb
external cb
iMin=0
iMax=10
i=winio@('Run the wheel up between these two numbers %6rd%6rd&', iMin, iMax)
i=winio@(' %dd%il%6rd%`il%ff&', 1, iMin, iMax, ival)
i=winio@('%^bt[Change limits]&', cb)
i=winio@('%ac[esc]','exit')
end
integer function cb ()
common iMin, iMax, iVal
i=winio@('%cn Change the wheel limits %6rd%6rd&', iMin, iMax)
i=winio@('%ac[esc]','exit')
call window_update@(iMin)
call window_update@(iMax)
cb=2
end function
Besides, if happen that the limits in %il have equal values it crashes the code, which at least it shouldn't do, the control must just do nothing