Update of /cvsroot/pure-data/pd/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25970
Modified Files: Tag: devel_0_39 desire.tk Log Message: fixed ctrl+e and also the hand in the buttonbar. (editmode)
Index: desire.tk =================================================================== RCS file: /cvsroot/pure-data/pd/src/Attic/desire.tk,v retrieving revision 1.1.2.453 retrieving revision 1.1.2.454 diff -C2 -d -r1.1.2.453 -r1.1.2.454 *** desire.tk 3 Sep 2006 16:46:22 -0000 1.1.2.453 --- desire.tk 4 Sep 2006 01:11:04 -0000 1.1.2.454 *************** *** 1226,1240 **** def Canvas editmode= {mode} { set @editmode $mode ! #sets the edit_toggle so the edit mode checkbox will follow if key binding is used ! catch {.$self.bbar.edit configure -image icon_mode_$mode} ! $self changed ;#$self draw ! } ! def Canvas editmodeswitch {args} { ! global crosshair ! set @editmode [expr !$@editmode] if {[$self look hairstate] && !$@editmode} {$@crosshair erase} ! pd .$self editmode $@editmode }
def Canvas window {} {return .$self} def Canvas widget {} {return .$self.c} --- 1226,1241 ---- def Canvas editmode= {mode} { set @editmode $mode ! # catch {.$self.bbar.edit configure -image icon_mode_$mode} ! if {$mode} { ! .$self.bbar.edit configure -image icon_mode_edit ! } else { ! .$self.bbar.edit configure -image icon_mode_run ! } if {[$self look hairstate] && !$@editmode} {$@crosshair erase} ! $self changed ! #!@#$ should update the checkbox in the editmenu }
+ def Canvas editmodeswitch {args} {$self editmode= [expr !$@editmode]} def Canvas window {} {return .$self} def Canvas widget {} {return .$self.c} *************** *** 1272,1276 **** set @wires_pair {} ;# stores wires in the format of {0 1 1 0} id {1 1 2 0} id $self init_window - $self editmode= 0 $self new_menubar $self new_binds --- 1273,1276 ---- *************** *** 1294,1297 **** --- 1294,1298 ---- set @copy_count 0 set @crosshair [Crosshair new $self] + $self editmode= 0 }
*************** *** 4505,4509 **** if {!$buttons_loaded} {load_button_bar} frame $bb ! pack [button $bb.edit -image icon_mode_edit -border 1 -command "$@canvas editmode= 1"] -side left foreach e $butt { mset {icon name cmd} $e --- 4506,4510 ---- if {!$buttons_loaded} {load_button_bar} frame $bb ! pack [button $bb.edit -image icon_mode_edit -border 1 -command "$@canvas editmodeswitch"] -side left foreach e $butt { mset {icon name cmd} $e