Update of /cvsroot/pure-data/pd/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12188
Modified Files: Tag: devel_0_39 desire.tk Log Message: extracted defaults.ddrc as a separate file
Index: desire.tk =================================================================== RCS file: /cvsroot/pure-data/pd/src/Attic/desire.tk,v retrieving revision 1.1.2.424 retrieving revision 1.1.2.425 diff -C2 -d -r1.1.2.424 -r1.1.2.425 *** desire.tk 30 Aug 2006 00:26:15 -0000 1.1.2.424 --- desire.tk 30 Aug 2006 03:35:24 -0000 1.1.2.425 *************** *** 494,497 **** --- 494,499 ---- } #-----------------------------------------------------------------------------------# + + #!@#$ is this still valid? set look(Box:extrapix) [switch $OS { osx {concat 2} *************** *** 500,647 **** #font is defined as Thing for now, as fontbomb and (later on the completion) needs #to get to these ones. ! set look(Thing:fontsize) 12 ! set look(Thing:fontfamily) courier ! set look(Thing:fontstyle) normal ! set look(Thing:fontitalic) 0 ! set look(Thing:fontstring2) "-*-courier-medium--normal--%d-*" ! set look(Thing:fontstring) [format -*-courier-medium--normal--%d-* $look(Thing:fontsize)] ! set look(Thing:fontwidth) [font measure $look(Thing:fontstring) W] ! set look(Thing:fontheight) [font metrics $look(Thing:fontstring) -linespace] ! set look(Thing:fontpady) 3 ! set look(Thing:fontpadx) 5 ! set look(View:tooltip) 1 ! set look(View:iowidth) 7 ! set look(View:minobjwidth) 21 ! set look(View:iopos) 0 ! set look(View:inletfg) #ff0000 ! set look(View:outletfg) #ff0000 ! set look(View:selectframe) #0080ff ! set look(View:fg) #000000 ! set look(View:bg) #ffffff ! set look(View:frame1) #99cccc ! set look(View:frame2) #668888 ! set look(View:frame3) #000000 ! set look(Comment:fg) #000000 ! set look(Comment:bg) #cccccc ! set look(Comment:frame1) #ffffff ! set look(Comment:frame2) #888888 ! set look(Comment:frame3) #cccccc ! set look(Canvas:bgrun) #ffffff ! set look(Canvas:bgedit) #dddddd ! set look(Canvas:crosshair) #ff14ff ! set look(Canvas:buttonbar) 1 ! set look(Canvas:statusbar) 1 ! set look(Canvas:hairstate) 1 ! set look(Canvas:hairsnap) 1 ! set look(SelRect:rect) #ff12ff ! set look(Wire:fg) #888888 ! set look(Wire:dspfg) #890098 ! set look(Wire:fg2) #ee0000 ! set look(Wire:thick) 1 ! set look(FutureWire:dash) #ee0012 ! set look(Slider:bg) #ccebff ! set look(Canvas:showcomp) 10 ! set look(Canvas:compfg) #000000 ! set look(Canvas:compbg) #ffffff ! set look(Canvas:compselectbg) #000000 ! set look(Canvas:compselectfg) #ffffff
set zoom(canned) [list 25 33 50 75 100 125 150 200 250 300 400] set scale(amount) 0.1 #-----------------------------------------------------------------------------------# - set key(Canvas:Object) "Ctrl+1" - set key(Canvas:Message) "Ctrl+2" - set key(Canvas:Number) "Ctrl+3" - set key(Canvas:Symbol) "Ctrl+4" - set key(Canvas:Comment) "Ctrl+5" - set key(Canvas:Bang) "Alt+b" - set key(Canvas:Toggle) "Alt+t" - set key(Canvas:Number2) "Alt+n" - set key(Canvas:Vslider) "Alt+v" - set key(Canvas:Hslider) "Alt+h" - set key(Canvas:Vradio) "Alt+d" - set key(Canvas:Hradio) "Alt+i" - set key(Canvas:VU) "Alt+u" - set key(Canvas:dropper) "Alt+x" - set key(Canvas:Canvas) "Alt+c" - set key(Canvas:Graph) "" - set key(Canvas:Array) "" - set key(Canvas:parentwindow) "" - set key(Canvas:Pdwindow) "" - set key(Canvas:new_file) "Ctrl+n" - set key(Canvas:open_file) "Ctrl+o" - set key(Canvas:quit) "Ctrl+q" - set key(Canvas:find) "Ctrl+f" - set key(Canvas:find_again) "Ctrl+g" - set key(Canvas:find_last_error) "" - set key(Canvas:class_browser) "" - set key(Canvas:close) "Ctrl+w" - set key(Canvas:save) "Ctrl+s" - set key(Canvas:save_as) "Ctrl+S" - set key(Canvas:cut) "Ctrl+x" - set key(Canvas:copy) "Ctrl+c" - set key(Canvas:print) "Ctrl+p" - set key(Canvas:undo) "Ctrl+z" - set key(Canvas:redo) "Ctrl+Z" - set key(Canvas:paste) "Ctrl+v" - set key(Canvas:duplicate) "Ctrl+d" - set key(Canvas:select_all) "Ctrl+a" - set key(Canvas:tidy_up) "" - set key(Canvas:reload) "Ctrl+r" - set key(Canvas:redraw) "" - set key(Canvas:crosshair) "" - set key(Canvas:editmodeswitch) "Ctrl+e" - set key(Canvas:popup_properties) "" - set key(Canvas:popup_help) "" - set key(Canvas:popup_open) "" - set key(Canvas:key_nav_up) "Ctrl+up" - set key(Canvas:key_nav_down) "Ctrl+down" - set key(Canvas:key_nav_right) "Ctrl+right" - set key(Canvas:key_nav_left) "Ctrl+left" - set key(Canvas:key_nav_up_shift) "Ctrl+UP" - set key(Canvas:key_nav_down_shift) "Ctrl+DOWN" - set key(Canvas:key_nav_right_shift) "Ctrl+RIGHT" - set key(Canvas:key_nav_left_shift) "Ctrl+LEFT" - set key(Canvas:key_nav_ioselect) "Ctrl+tab" - set key(Canvas:incr_zoom) "Ctrl+equal" - set key(Canvas:decr_zoom) "Ctrl+minus" - set key(Canvas:incr_scale) "Ctrl+PLUS" - set key(Canvas:decr_scale) "Ctrl+UNDERSCORE" - set key(Canvas:send_message) "Ctrl+m" - set key(Canvas:paths) "" - set key(Canvas:text_editor) "Ctrl+t" - set key(Canvas:font_bomb) "Ctrl+F" - set key(Canvas:audio_on) "Ctrl+slash" - set key(Canvas:audio_off) "Ctrl+period" - set key(Canvas:load_meter) "" - set key(Canvas:latency_meter) "" - set key(Canvas:about) "" - - set key(Client:new_file) "Ctrl+n" - set key(Client:open_file) "Ctrl+o" - set key(Client:pdrc_editor) "Ctrl+p" - set key(Client:ddrc_editor) "Ctrl+l" - set key(Client:send_message) "Ctrl+m" - set key(Client:paths) "" - set key(Client:quit) "Ctrl+q" - set key(Client:find) "Ctrl+f" - set key(Client:find_again) "Ctrl+g" - set key(Client:find_last_error) "" - set key(Client:audio_on) "Ctrl+slash" - set key(Client:audio_off) "Ctrl+period" - set key(Client:audio_settings) "" - set key(Client:midi_settings) "" - set key(Client:test_audio_and_midi) "" - set key(Client:load_meter) "" - set key(Client:latency_meter) "" - set key(Client:about) "" - set key(Client:class_browser) "" - set key(Client:text_editor) "Ctrl+t" - set key(Client:font_bomb) "" - set key(Client:client_class_tree) "Ctrl+grave" - set key(Client:Canvas) "Alt+c"
set accels {} ! foreach k [array names key] {dict set accels $key($k) $k}
################## set up main window ######################### --- 502,547 ---- #font is defined as Thing for now, as fontbomb and (later on the completion) needs #to get to these ones. ! ! #!@#$ Thing->View ! #set look(Thing:fontsize) 12 ! #set look(Thing:fontfamily) courier ! #set look(Thing:fontstyle) normal ! #set look(Thing:fontitalic) 0 ! #set look(Thing:fontstring2) "-*-courier-medium--normal--%d-*" ! #set look(Thing:fontstring) [format -*-courier-medium--normal--%d-* $look(Thing:fontsize)] ! #set look(Thing:fontwidth) [font measure $look(Thing:fontstring) W] ! #set look(Thing:fontheight) [font metrics $look(Thing:fontstring) -linespace] ! #set look(Thing:fontpady) 3 ! #set look(Thing:fontpadx) 5 ! ! #!@#$ View->Box ! #set look(View:iowidth) 7 ! #set look(View:inletfg) #ff0000 ! #set look(View:outletfg) #ff0000 ! #set look(View:selectframe) #0080ff ! #set look(View:iopos) 0 ! ! #!@#$ View->??? ! #set look(View:tooltip) 1 ! ! #!@#$ View->TextBox ? ! #set look(View:minobjwidth) 21 ! ! #!@#$ View->ObjectBox ! #set look(View:fg) #000000 ! #set look(View:bg) #ffffff ! #set look(View:frame1) #99cccc ! #set look(View:frame2) #668888 ! #set look(View:frame3) #000000 ! ! #!@#$ this is supposed to be BlueBox! ! #set look(Slider:bg) #ccebff
set zoom(canned) [list 25 33 50 75 100 125 150 200 250 300 400] set scale(amount) 0.1 #-----------------------------------------------------------------------------------#
set accels {} ! #foreach k [array names key] {dict set accels $key($k) $k}
################## set up main window ######################### *************** *** 966,971 **** }
- set main [Client new] - def Menuable eval% {code} { regsub -all %W $code $self code --- 866,869 ---- *************** *** 1036,1042 **** } #-----------------------------------------------------------------------------------# ! proc read_ddrc {} { ! global cmdline look key ! set fd [open $cmdline(ddrcfilename) "RDONLY CREAT"] set contents [read $fd] close $fd --- 934,944 ---- } #-----------------------------------------------------------------------------------# ! proc* read_ddrc {{filename ""}} { ! global cmdline look key accels ! if {$filename == ""} { ! set fd [open $cmdline(ddrcfilename) "RDONLY CREAT"] ! } else { ! set fd [open $filename] ! } set contents [read $fd] close $fd *************** *** 1046,1049 **** --- 948,952 ---- } } + foreach k [array names key] {dict set accels $key($k) $k} set_fontstring } *************** *** 1067,1070 **** --- 970,978 ---- set_fontstring } + if {[file exists "defaults.ddrc"]} { + read_ddrc "defaults.ddrc" + } else { + read_ddrc [list [file join [file dirname $argh0] "../lib/pd/bin/defaults.ddrc"]] + } read_ddrc #-----------------------------------------------------------------------------------# *************** *** 1081,1084 **** --- 989,994 ---- }
+ set main [Client new] + #-----------------------------------------------------------------------------------# #fixme: actually, is it ok that View<Menuable ? --matju *************** *** 1587,1594 **** -accelerator [accel_munge "Ctrl+e"] -indicatoron 1 \ -variable @editmode -onvalue 1 -offvalue 0 #binds the state of the checkbox to global variable editmod ! if {![dict exists $accels "Ctrl+e"]} { ! dict append accels $key(editmodeswitch) {[%W canvas] editmodeswitch} ! } $m.edit configure -postcommand "$self fix_edit_menu" $m.window configure -postcommand "$self fix_window_menu" --- 1497,1507 ---- -accelerator [accel_munge "Ctrl+e"] -indicatoron 1 \ -variable @editmode -onvalue 1 -offvalue 0 + + # what's this for??? --matju #binds the state of the checkbox to global variable editmod ! #if {![dict exists $accels "Ctrl+e"]} { ! # dict append accels $key(editmodeswitch) {[%W canvas] editmodeswitch} ! #} ! $m.edit configure -postcommand "$self fix_edit_menu" $m.window configure -postcommand "$self fix_window_menu" *************** *** 3474,3483 **** # yscale "" entry {-width 10} #} ! "pdtk_canvas_dialog %%s %g %g %d %g %g %g %g %d %d %d %d\n", ! glist_dpixtodx(x, 1), -glist_dpixtody(x, 1), ! 1, ! x->gl_x1, x->gl_y1, x->gl_x2, x->gl_y2, ! (int)x->gl_pixwidth, (int)x->gl_pixheight, ! (int)x->gl_xmargin, (int)x->gl_ymargin); $self add .$self $props pack [checkbutton .$self.graphme -text "graph on parent" \ --- 3387,3395 ---- # yscale "" entry {-width 10} #} ! #"pdtk_canvas_dialog %%s %g %g %d %g %g %g %g %d %d %d %d\n", ! #glist_dpixtodx(x, 1), -glist_dpixtody(x, 1), 1, ! #x->gl_x1, x->gl_y1, x->gl_x2, x->gl_y2, ! #(int)x->gl_pixwidth, (int)x->gl_pixheight, ! #(int)x->gl_xmargin, (int)x->gl_ymargin); $self add .$self $props pack [checkbutton .$self.graphme -text "graph on parent" \