Added vim swapfiles to ignore list
[tcl-tlc.git] / testinputs.tcl
bloba54ad8b2254c8980f9d62167da0a9bf8f36a52cc
1 #!/usr/bin/wish
3 package require TLC
4 namespace import tlc::*
5 eval [go_home]
7 wm deiconify .
9 checkbutton .i1 -text "i1" -command [list seti i1] -variable i1
10 checkbutton .i2 -text "i2" -command [list seti i2] -variable i2
11 checkbutton .i3 -text "i3i" -command [list seti i3] -variable i3
12 checkbutton .i4 -text "i4" -command [list seti i4] -variable i4
14 checkbutton .o -text "output" -variable o
16 proc seti {line} {
17 upvar ${line}_o obj
18 $obj set_state [set ::${line}]
21 proc linechange {linestate} {
22 set ::o $linestate
26 Signal #auto i1_o
27 Signal #auto i2_o
28 Signal #auto i3_o
29 Signal #auto i4_o
31 Gate #auto logic -mode and
32 if {0} {
33 $logic attach_input $i1_o
34 $logic attach_input $i2_o
35 $logic attach_input $i3_o inverted
36 $logic attach_input $i4_o
37 } else {
38 $logic attach_var_input ::i1
39 $logic attach_var_input ::i2
40 $logic attach_var_input ::i3 inverted
41 $logic attach_var_input ::i4
44 $logic attach_output ::linechange
47 table . -padx 5 -pady 5 \
48 .i1 1,1 \
49 .i2 2,1 \
50 .i3 3,1 \
51 .i4 4,1 \
52 .o 1,2 -rspan 4