Tk Source Code

View Ticket
Login
Ticket UUID: f9116b31ac33bb852fc05a96a5f968a09b818ed3
Title: Deselect radiobutton
Type: Bug Version: 8.6
Submitter: anonymous Created on: 2018-09-16 09:03:49
Subsystem: (unused) Assigned To: nobody
Priority: 5 Medium Severity: Minor
Status: Closed Last Modified: 2018-09-16 13:48:47
Resolution: Duplicate Closed By: fvogel
    Closed on: 2018-09-16 13:48:47
Description:
Bll submit  : deselect is not supported ? But deselect is in current doc 8.6
https://www.tcl.tk/man/tcl/TkCmd/radiobutton.htm
Furthermore the soluce proposed not work set reptyp 0, the only soluce work is to activate tk_messageBox.
This code is one example my code is very long to submit  here.

Regards

Code :

frame .t
pack .t
set reptype 0
radiobutton .t.r1 -text "1" -variable reptyp -value 1
radiobutton .t.r2 -text "2" -variable reptyp -value 2
radiobutton .t.r3 -text "3" -variable reptyp -value 3
radiobutton .t.r4 -text "4" -variable reptyp -value 4
radiobutton .t.r5 -text "5" -variable reptyp -value 5
radiobutton .t.r6 -text "6" -variable reptyp -value 6

bind .t.r1 <Double-1> {Chk_Alone $reptyp}
bind .t.r2 <Double-1> {Chk_Alone $reptyp}
bind .t.r3 <Double-1> {Chk_Alone $reptyp}
bind .t.r4 <Double-1> {Chk_Alone $reptyp}
bind .t.r5 <Double-1> {Chk_Alone $reptyp}
bind .t.r6 <Double-1> {Chk_Alone $reptyp}


grid .t.r1
grid .t.r2 
grid .t.r3
grid .t.r4
grid .t.r5
grid .t.r6

proc Chk_Alone {args} {
global reptyp

#tk_messageBox -message "unselected"
after idle [list .t.r$args deselect] 
set reptyp 0
}
User Comments: fvogel added on 2018-09-16 13:48:47:

Oops, wrong link sorry. This is actually a duplicate of [c92cee47].


fvogel added on 2018-09-16 13:45:19:

Please don't open a new ticket when replying. Use the Edit button instead.

This is a duplicate of [75a9388f]. Closing as such.