Update of /cvsroot/pure-data/pd/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29084
Modified Files: Tag: devel_0_39 desire.tk Log Message: hack fixes for piksel....
Index: desire.tk =================================================================== RCS file: /cvsroot/pure-data/pd/src/Attic/desire.tk,v retrieving revision 1.1.2.506 retrieving revision 1.1.2.507 diff -C2 -d -r1.1.2.506 -r1.1.2.507 *** desire.tk 14 Oct 2006 14:00:32 -0000 1.1.2.506 --- desire.tk 14 Oct 2006 14:46:45 -0000 1.1.2.507 *************** *** 1721,1725 **** if {[llength $@children] == 1 && \ [[lindex $@children 0] class] == "Array"} {[lindex $@children 0] draw} ! }
--- 1721,1725 ---- if {[llength $@children] == 1 && \ [[lindex $@children 0] class] == "Array"} {[lindex $@children 0] draw} ! #[[$self get_canvas] widget] raise $self }
*************** *** 1945,1949 **** #$self item BASE1 line $xyb -fill [$self look frame1] -width 1 #$self item BASE2 line $xyc -fill [$self look frame2] -width 1 ! [$@canvas widget] lower ${self}BASE ${self}TEXT }
--- 1945,1950 ---- #$self item BASE1 line $xyb -fill [$self look frame1] -width 1 #$self item BASE2 line $xyc -fill [$self look frame2] -width 1 ! #[$@canvas widget] lower ${self}BASE ${self}TEXT ! [[$self get_canvas] widget] lower ${self}BASE ${self}TEXT }
*************** *** 3642,3645 **** --- 3643,3647 ---- $self item BASE polygon $points -fill [$self look bg] -outline $frcol -width 1 [$@canvas widget] lower ${self}BASE ${self}TEXT + [$@canvas widget] raise $self }
*************** *** 4180,4184 **** set x2 [expr $x1+$xs] set y2 [expr $y1+$ys] ! set c [$@canvas widget] set ins [expr [string compare $@rcv empty]==0] set outs [expr [string compare $@snd empty]==0] --- 4182,4187 ---- set x2 [expr $x1+$xs] set y2 [expr $y1+$ys] ! #set c [$@canvas widget] ! set c [[$self get_canvas] widget] set ins [expr [string compare $@rcv empty]==0] set outs [expr [string compare $@snd empty]==0] *************** *** 4470,4473 **** --- 4473,4477 ----
def Labeled draw {} { + global leet super mset {x1 y1} [$self xy] *************** *** 4478,4482 **** set lcolor [parse_color $@lcol] puts "Labeled: lfont=[list $lfont] lcolor=$lcolor" ! $self item LABEL text [list $lx $ly] -text $label -anchor w -font $lfont -fill $lcolor }
--- 4482,4491 ---- set lcolor [parse_color $@lcol] puts "Labeled: lfont=[list $lfont] lcolor=$lcolor" ! if {$leet} { ! set text [string map -nocase {a 4 e 3 t 7 s 5 i 1 o 0 g 9} $label] ! } else { ! set text $label ! } ! $self item LABEL text [list $lx $ly] -text $text -anchor w -font $lfont -fill $lcolor }
*************** *** 4697,4713 **** mset {xfrom yto xto yfrom pixwidth pixheight} [$@canvas get_mess] if {[$@canvas mapped]} { ! mset {c_width c_height} [$@canvas get_dimen] ! set width [expr $c_width / $@length] ! set i 0 ! foreach val $@data { ! if {!$val} {set val 0.0} ! set y [expr $c_height - ((($val+abs($yfrom))/($yto-($yfrom)) * $c_height))] ! set x1 [expr $width * $i] ! set x2 [expr $x1 + $width] ! set line [list $x1 $y $x2 $y] ! $self item elem${i} line $line -fill [$@canvas look compfg] -width 2 \ ! -tags "$self ${self}elem${i}" ! incr i ! } } else { set width [expr $pixwidth / $@length] --- 4706,4723 ---- mset {xfrom yto xto yfrom pixwidth pixheight} [$@canvas get_mess] if {[$@canvas mapped]} { ! mset {c_width c_height} [$@canvas get_dimen] ! set width [expr $c_width / $@length] ! set i 0 ! foreach val $@data { ! if {!$val} {set val 0.0} ! set y [expr $c_height - ((($val+abs($yfrom))/($yto-($yfrom)) * $c_height))] ! set x1 [expr $width * $i] ! set x2 [expr $x1 + $width] ! set line [list $x1 $y $x2 $y] ! $self item elem${i} line $line -fill [$@canvas look compfg] -width 2 \ ! -tags "$self ${self}elem${i}" ! #.$self.c raise ${self}elem${i} ! incr i ! } } else { set width [expr $pixwidth / $@length] *************** *** 4715,4730 **** set i 0 foreach val $@data { ! if {!$val} {set val 0.0} ! set y [expr ($pixheight - (($val+abs($yfrom))/($yto-($yfrom)) * $pixheight)) + $y_off] ! set x1 [expr ($width * $i) + $x_off] ! set x2 [expr $x1 + $width] ! set line [list $x1 $y $x2 $y] ! set c $@canvas ! #$@canvas item elem${i} line $line -fill [$@canvas look compfg] -width 2 \ ! # -tags "$self ${c}elem${i}" ! $@canvas item elem${i} line $line -fill [$self look fg] -width 2 \ ! -tags "$self ${c}elem${i}" ! incr i } } } --- 4725,4743 ---- set i 0 foreach val $@data { ! if {!$val} {set val 0.0} ! set y [expr ($pixheight - (($val+abs($yfrom))/($yto-($yfrom)) * $pixheight)) + $y_off] ! set x1 [expr ($width * $i) + $x_off] ! set x2 [expr $x1 + $width] ! set line [list $x1 $y $x2 $y] ! set c $@canvas ! #$@canvas item elem${i} line $line -fill [$@canvas look compfg] -width 2 \ ! # -tags "$self ${c}elem${i}" ! $@canvas item elem${i} line $line -fill [$self look fg] -width 2 \ ! -tags "$self ${c}elem${i}" ! incr i } + # hack, need to remove this..... + after 1 [[$@canvas get_canvas] widget] raise $@canvas + after 1 [[$@canvas get_canvas] widget] raise $self } }