摘要: set l [list a bc def 1 23 456]set m 0foreach i $l { incr m puts "member $m is $i"}for {set x 0} {$x<10} {incr x} { puts "x is $x"}set x 0while {$x<10} { puts "x is $x" incr x}This command is typically invoked inside the body of a looping command such as for or for 阅读全文
posted @ 2011-08-10 16:38 greencolor 阅读(99) 评论(0) 推荐(0) 编辑
摘要: class cc {inherit itk::Widgetpublic method changtext#array aaritk_option define -textbackground textBackground Background "\#ff0000"constructor {args} {itk_component add linetwo { button $itk_component(hull).d \ -text "bbb"} itk_component add buttontwo { button $itk_component(hul 阅读全文
posted @ 2011-08-10 15:05 greencolor 阅读(166) 评论(0) 推荐(0) 编辑
摘要: class cc {inherit itk::Widgetproc changtextconstructor {args} {itk_component add linetwo { label $itk_component(hull).d \ -text "bbb" }itk_component add buttontwo { button $itk_component(hull).b \ -text "est" \ -command "$itk_component(hull) changtext ccc"}pack $itk_com 阅读全文
posted @ 2011-08-10 12:20 greencolor 阅读(100) 评论(0) 推荐(0) 编辑