[PD-cvs] pd/src desire.tk,1.1.2.374,1.1.2.375
chunlee
chunlee at users.sourceforge.net
Sat Aug 19 17:35:04 CEST 2006
Update of /cvsroot/pure-data/pd/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20146
Modified Files:
Tag: devel_0_39
desire.tk
Log Message:
small fixes to ddrc and ddrc editor, adding toggles to enable/disable buttonbar and status bar
Index: desire.tk
===================================================================
RCS file: /cvsroot/pure-data/pd/src/Attic/desire.tk,v
retrieving revision 1.1.2.374
retrieving revision 1.1.2.375
diff -C2 -d -r1.1.2.374 -r1.1.2.375
*** desire.tk 18 Aug 2006 16:16:29 -0000 1.1.2.374
--- desire.tk 19 Aug 2006 15:35:02 -0000 1.1.2.375
***************
*** 948,953 ****
set look(sliderbg) #ccebff
#set look(sliderbg) #ffeedd
! set look(buttonbar) 1
! set look(statusbar) 1
set look(showcomp) 10
set look(tooltip) 1
--- 948,953 ----
set look(sliderbg) #ccebff
#set look(sliderbg) #ffeedd
! set bar(buttonbar) 1
! set bar(statusbar) 1
set look(showcomp) 10
set look(tooltip) 1
***************
*** 963,967 ****
#-----------------------------------------------------------------------------------#
proc read_ddrc {} {
! global look crosshair
set file [open "~/.ddrc" "RDONLY CREAT"]
set dd_config [read $file]
--- 963,967 ----
#-----------------------------------------------------------------------------------#
proc read_ddrc {} {
! global look crosshair bar
set file [open "~/.ddrc" "RDONLY CREAT"]
set dd_config [read $file]
***************
*** 978,982 ****
crosshair {
set crosshair($word2) $word3
! #puts "look($word2) $word3"
}
font {
--- 978,984 ----
crosshair {
set crosshair($word2) $word3
! }
! bar {
! set bar($word2) $word3
}
font {
***************
*** 1299,1307 ****
def Canvas init_window {} {
set win .$self
set c .$self.c
toplevel $win -menu $win.m
# turn buttonbar on/off
! if {[look buttonbar]} {
if {[catch {pack [[ButtonBar new $self] widget] -side top -fill x -expand no}]} {
global errorInfo
--- 1301,1311 ----
def Canvas init_window {} {
+ global bar
+ puts " --- butt:: $bar(buttonbar) status::: $bar(statusbar)"
set win .$self
set c .$self.c
toplevel $win -menu $win.m
# turn buttonbar on/off
! if {$bar(buttonbar)} {
if {[catch {pack [[ButtonBar new $self] widget] -side top -fill x -expand no}]} {
global errorInfo
***************
*** 1311,1315 ****
set @statusbar [StatusBar new $self]
# turn statusbar on/off
! if {[look statusbar]} {pack [$@statusbar widget] -side bottom -fill x}
pack [scrollbar $win.xscroll -command "$c xview" -orient horizontal] -side bottom -fill x
pack [scrollbar $win.yscroll -command "$c yview" ] -side right -fill y
--- 1315,1319 ----
set @statusbar [StatusBar new $self]
# turn statusbar on/off
! if {$bar(statusbar)} {pack [$@statusbar widget] -side bottom -fill x}
pack [scrollbar $win.xscroll -command "$c xview" -orient horizontal] -side bottom -fill x
pack [scrollbar $win.yscroll -command "$c yview" ] -side right -fill y
***************
*** 2675,2679 ****
def Canvas decr_zoom {} {$self zoom "out"}
def Canvas zoom {mode} {
! global scale
set spinbox .$self.bbar.scale
set val [string trimright [$spinbox get] %]
--- 2679,2683 ----
def Canvas decr_zoom {} {$self zoom "out"}
def Canvas zoom {mode} {
! global scale bar
set spinbox .$self.bbar.scale
set val [string trimright [$spinbox get] %]
***************
*** 2688,2691 ****
--- 2692,2696 ----
set @scale [expr $per/100.0] ;# @scale must be float, not int
$self redraw
+
}
***************
*** 4723,4727 ****
class_new Dialog {Thing}
! def Dialog add {w args} {
set no_max_label 0
foreach row $args {
--- 4728,4732 ----
class_new Dialog {Thing}
! def* Dialog add {w args} {
set no_max_label 0
foreach row $args {
***************
*** 4732,4735 ****
--- 4737,4741 ----
set label "[say $name]: "
set k [lsearch $options -choices]
+ puts " name: $name | type: $type | option: $options | k: $k"
if {$k>=0} {
set choices [lindex $options [expr $k+1]]
***************
*** 4799,4803 ****
set text ""
set n 0
! foreach item $choices {
if {$n != 0} {append text " & " [say $item]} else {set text [say $item]}
incr n
--- 4805,4813 ----
set text ""
set n 0
! #foreach item $choices {
! # if {$n != 0} {append text " & " [say $item]} else {set text [say $item]}
! # incr n
! #}
! foreach item $name {
if {$n != 0} {append text " & " [say $item]} else {set text [say $item]}
incr n
***************
*** 5257,5261 ****
libraries {incr i; lappend @$name [lindex $contents $i]}
files {incr i; lappend @$name [lindex $contents $i]}
! choice { set @$name [lsearch $name [lindex $contents $i]}
void { set @$name 1}
default {incr i; set @$name [lindex $contents $i]}
--- 5267,5271 ----
libraries {incr i; lappend @$name [lindex $contents $i]}
files {incr i; lappend @$name [lindex $contents $i]}
! choice { set @$name [lsearch $name [lindex $contents $i]]}
void { set @$name 1}
default {incr i; set @$name [lindex $contents $i]}
***************
*** 5385,5388 ****
--- 5395,5400 ----
crosshair hairstate
crosshair hairsnap
+ bar buttonbar
+ bar statusbar
}
***************
*** 5391,5395 ****
def* ClientPrefsDialog read {} {
! global ddrc_options ddrc_options_h cmdline look key crosshair
set fd [open $cmdline(ddrcfilename) "RDONLY CREAT"]
#set contents [split [string map {"\n" " "} [read $fd]] " "]
--- 5403,5407 ----
def* ClientPrefsDialog read {} {
! global ddrc_options ddrc_options_h cmdline look key crosshair bar
set fd [open $cmdline(ddrcfilename) "RDONLY CREAT"]
#set contents [split [string map {"\n" " "} [read $fd]] " "]
***************
*** 5417,5420 ****
--- 5429,5433 ----
key {set key($item) $value}
crosshair {set crosshair($item) $value; set _($self:crosshair($item)) $value}
+ bar {set bar($item) $value; set _($self:bar($item)) $value}
default {incr i; set @$name [lindex $contents $i]}
}
***************
*** 5463,5466 ****
--- 5476,5483 ----
puts $fd "$type $name $crosshair($name)"
}
+ bar {
+ set bar($name) $_($self:$name)
+ puts $fd "$type $name $bar($name)"
+ }
}
}
***************
*** 5470,5474 ****
}
def ClientPrefsDialog init {} {
! global ddrc_options look key crosshair
$self read
super reset cancel apply ok
--- 5487,5491 ----
}
def ClientPrefsDialog init {} {
! global ddrc_options look key crosshair bar
$self read
super reset cancel apply ok
***************
*** 5522,5525 ****
--- 5539,5543 ----
set @$var $which_section.[string tolower [lindex $name 0]].[string tolower $item]
}
+ puts " name::: $name"
$self add $which_section [list $name $type]
}
***************
*** 5531,5534 ****
--- 5549,5558 ----
$self add $which_section [list [lindex $name 0] toggle]
}
+ bar {
+ set var ${name}path
+ set @$var $which_section.$name.color
+ set @$name $bar($name)
+ $self add $which_section [list [lindex $name 0] toggle]
+ }
default {
$self add $which_section [list $name $type]
More information about the Pd-cvs
mailing list