How can I select/unselect a custom control ?
It seems to me there are no functions to set/unset the select state of a custom
control,
neither it changes state as you click on it or on another control in the same
dialog.
In the following example I would like to change from selected state (Red) to
Unselected (Green).
Any suggestion ?
Regards
Maurizio
module hello
import StdEnv, StdIO
Start world
#(ids,world) = openIds 2 world
= startIO NDI "ps" (snd o openDialog 1 (hello ids) ) [ProcessClose
closeProcess] world
where
hello [id1,id2] = Dialog "Hello dialog"
(CustomControl {w=50,h=30} showcustom [ ControlPos (Left, zero)
, ControlId id1
, ControlSelectState Able
, ControlFunction myfun
]
:+:
EditControl "" (PixelWidth 100) 1 [ControlPos (Left, zero), ControlId
id2]
)
[ WindowClose (noLS closeProcess)
, WindowViewSize {w=150, h=80}
, WindowPos (Fix, OffsetVector {vx=400, vy=350})
]
myfun st = st
showcustom Able {newFrame} picture
# picture = setPenColour Red picture
= fill newFrame picture
showcustom Unable {newFrame} picture
# picture = setPenColour Green picture
= fill newFrame picture
-----------------------------------------------------------------------------
Il presente messaggio, corredato dei relativi allegati, contiene informazioni
da considerarsi strettamente riservate ed è destinato esclusivamente al
destinatario sopra indicato, il quale è l'unico autorizzato ad usarlo, copiarlo
e, sotto la propria responsabilità, diffonderlo. Chiunque ricevesse questo
messaggio per errore o comunque lo leggesse senza esserne legittimato è
avvertito che trattenerlo, copiarlo, divulgarlo, distribuirlo a persone diverse
dal destinatario è severamente proibito, ed è pregato di rinviarlo
immediatamente al mittente distruggendone l'originale.
This message, together with its annex(es), contains information to be deemed
strictly confidential and is destined only to the addressee(s) identified above
who only may use, copy and, under his/their responsibility, further disseminate
it. If anyone received this message by mistake or reads it without entitlement
is forewarned that keeping, copying, disseminating or distributing this message
to persons other than the addressee(s) is strictly forbidden and is asked to
transmit it immediately to the sender and to erase the original message
received.
_______________________________________________
clean-list mailing list
[email protected]
http://mailman.science.ru.nl/mailman/listinfo/clean-list