Paul,
I noticed one strange conflict of this formatting method with my existing code. First example is a demo showing how my code was working before adding this upgrade. If you wiggle slider %sl its value is displayed in the %rf control. You also can change the value directly using %df or typing new value between 0 an 1. The value changes OK in both %rf control and in the slider handle.
module MOD1
real*8 :: var1=0, var2=0
Contains
integer function fun1 ()
var2 = var1
call window_update@(var2)
fun1 = 2
end function fun1
integer function fun2 ()
var1 = var2
call window_update@(var1)
fun2 = 2
end function fun2
end module MOD1
!.....................
Program OK
use mod1
i=winio@('%ww%ca[Conflict in form]&')
i=winio@('%^30sl[horizontal] %df%^8rf%ff&',var1, 0d0,1d0, fun1, 0.1d0, var2,fun2 )
i=winio@('%nl%cn%bt[OK]%es')
END
Second example where i add this [form=] method shows that my code fails when you use %df or directly type the value - the slider does not react on that anymore
module MOD1
real*8 :: var1=0, var2=0
Contains
integer function fun1 ()
var2 = var1
call window_update@(var2)
fun1 = 2
end function fun1
integer function fun2 ()
var1 = var2
call window_update@(var1)
fun2 = 2
end function fun2
end module MOD1
!.....................
Program CONFL
use mod1
i=winio@('%co[check_on_focus_loss]&')
i=winio@('%ww%ca[Conflict in form]&')
i=winio@('%^30sl[horizontal] %df%^11rf[fmt=0.3e]%ff&',var1, 0d0,1d0, fun1, 0.1d0, var2,fun2 )
i=winio@('%nl%cn%bt[OK]%es')
END
These were two methods of controlling numerous different parameters, slider was quick and %df%rf more accurate. I have many such sliders. Now the accurate method does not work.
ADDITION
May be i over-complicated things a bit with two variables and two callbacks doing the same things to avoid stucking (when you try to move slider but displayed in %rf variable trying to move slider back) so i separated them.
I found simpler version with just one variable and one callback also works, i do not know why it did not work before
module MOD1
real*8 :: var1=0
Contains
integer function fun3 ()
call window_update@(var1)
fun3 = 2
end function fun3
end module MOD1
!.....................
Program OK2
use mod1
i=winio@('%ww%ca[Not Working]&')
i=winio@('%^30sl[horizontal] %df%^11rf%ff&',var1, 0d0,1d0, fun3, 0.1d0, var1,fun3 )
i=winio@('%nl%cn%bt[OK]%es')
END
but again if i add there FMT= it stops working too
module MOD1
real*8 :: var1=0
Contains
integer function fun3 ()
call window_update@(var1)
fun3 = 2
end function fun3
end module MOD1
!.....................
Program CONFL2
use mod1
i=winio@('%ww%ca[Not Working]&')
i=winio@('%co[check_on_focus_loss]&')
i=winio@('%^30sl[horizontal] %df%^11rf[fmt=0.3e]%ff&',var1, 0d0,1d0, fun3, 0.1d0, var1,fun3 )
i=winio@('%nl%cn%bt[OK]%es')
END