Documentation‎ > ‎Display‎ > ‎

gnocl::level





-active
-name
-visible
-tooltip

cget
class
configure
delete
get
set <integer> (range 0-100)


# test-level.tcl

#!./bin/sh
#\
exec tclsh "$0" "$@"

package require Gnocl

proc display {} {
    global lev
    set hb(1) [gnocl::hBox]
        for {set i 0} {$i<20} {incr i} {
            set lev($i) [gnocl::level]
            $hb(1) add $lev($i) -padding 0
            $lev($i) set [expr $i * 10]
        }

    set eb [gnocl::eventBox -background black -child $hb(1)]
    return $eb
}


proc draw {} {
    global lev
        for {set i 0} {$i<[array size lev]} {incr i} {
            set val [expr 50+ int ( rand() * 50) ]
            $lev($i) set $val
      
        }

    after 100 draw
}

gnocl::window -child [display]
draw




Comments