Revision: 10467 http://pure-data.svn.sourceforge.net/pure-data/?rev=10467&view=rev Author: chunlee Date: 2008-12-28 08:37:30 +0000 (Sun, 28 Dec 2008)
Log Message: ----------- pd_say.tcl, locale
Modified Paths: -------------- branches/pd-devel/0.41.4/src/pd.tk branches/pd-devel/0.41.4/src/pd_menus.tcl branches/pd-devel/0.41.4/src/pkgIndex.tcl
Added Paths: ----------- branches/pd-devel/0.41.4/src/locale/ branches/pd-devel/0.41.4/src/locale/chinese.tcl branches/pd-devel/0.41.4/src/pd_say.tcl
Added: branches/pd-devel/0.41.4/src/locale/chinese.tcl =================================================================== --- branches/pd-devel/0.41.4/src/locale/chinese.tcl (rev 0) +++ branches/pd-devel/0.41.4/src/locale/chinese.tcl 2008-12-28 08:37:30 UTC (rev 10467) @@ -0,0 +1,556 @@ +### Menus + +say file "案檔" + say new_file "新案檔" + say open_file "開啟舊檔..." + say server_prefs "伺服器設定..." + say client_prefs "客戶端設定..." + say send_message "傳送旨令..." + say paths "Paths..." + say close "關閉" + say save "存檔" + say save_as "另存新檔..." + say print "印出..." + say quit "結束" + + say canvasnew_file "開啟新檔" + say canvasopen_file "開啟舊檔..." + say canvassave "存檔" + say canvassave_as "另存新檔..." + say clientpdrc_editor "遠端設定" + say clientddrc_editor "終端設定" + say canvasclose "關閉" + say canvasquit "結束" + +say edit "編輯" + say undo "回上一步" + say redo "回下一步" + say cut "剪下" + say copy "拷貝" + say paste "後貼" + say duplicate "復製" + say select_all "全選" + say text_editor "Text Editor..." + say font "字體" + say tidy_up "自動排列" + say edit_mode "編輯模式" + say editmodeswitch "編輯/執行 模式" + + say canvascut "剪下" + say canvascopy "拷貝" + say canvasundo "回上一步" + say canvasredo "回下一步" + say canvaspaste "後貼" + say canvasduplicate "復製" + say canvasselect_all "全選" + say canvaseditmodeswitch "編輯/執行 模式" + +say view "顯示" + say reload "重新下載" + say redraw "重新畫製" + + say canvasreload "重新下載" + say canvasredraw "重新畫製" + +say find "尋找" + say find_again "再次尋找" + say find_last_error "尋找上一錯誤" + say string "Find string" +say canvasfind "尋找" + say canvasfind_again "再次尋找" + +# contents of Put menu is Phase 5C +say put "放置" + say Object "物件" + say Message "信息" + say Number "數字" + say Symbol "符號" + say Comment "註譯" + say Graph "圖" + say Array "陣列" + +say media "Media" + say audio_on "聲頻開啟" + say audio_off "聲頻關閉" + say test_audio_and_midi "測試聲頻及MIDI" + say load_meter "負載錶" + + say canvasaudio_on "聲頻開啟" + say canvasaudio_off "聲頻關閉" + say clienttest_audio_and_midi "測試聲頻及MIDI" + say canvasload_meter "負載錶" + +say window "視窗" + +say help "幫助" + say about "相關..." + say documentation "使用說明..." + say class_browser "物件瀏覽器..." + + say canvasabout "相關..." + +say properties "內容" +say open "開啟" + +### for key binding editor +say general "一般" +say audio_settings "聲頻設定" +say midi_settings "Midi設定" +say latency_meter "時延錶" +say Pdwindow "Pd主視窗" + +say canvaspdwindow "Pd主視窗" +say canvaslatency_meter "時延錶" +say clientaudio_settings "聲頻設定" +say clientmidi_settings "Midi設定" + +### for Properties Dialog (phase 5B) +say_category IEM +say w "寬(像素)" +say h "高(像素)" +say hold "有效顯示時限(毫秒)" +say break "有效空閒時限(毫秒)" +say min "最低數限" +say max "最高數限" +say is_log "模式" +say linear "線性" +say logarithmic "對數" +say isa "起始" +say n "選擇數量" +say steady "穩定性" +say steady_no "點選跳躍式" +say steady_yes "點選持續式" +say snd "傳送符號" +say rcv "接收符號" +say lab "標簽" +say ldx "標簽橫落差" +say ldy "標簽縱落差" +say fstyle "字形" +say fs "字體大小" +say bcol "背景研色" +say fcol "前景研色" +say lcol "標簽研色" +say yes "是" +say no "否" +say courier "courier (typewriter)" +say helvetica "helvetica (sansserif)" +say times "times (serif)" +say coords "頂端顯示" + +say_category GAtomProperties +say width "寬" +say lo "最低數限" +say hi "最高數限" +say label "標簽" +say wherelabel "標簽位置" +say symto "傳送符號" +say symfrom "接收符號" +say pos "標簽位置" +say_category GraphProperties +say x1 "x from" +say x2 "x to" +say xpix "screen width" +say y2 "y from" +say y1 "y to" +say ypix "screen height" + +say_category CanvasProperties +#say xscale "X units/px" +#say yscale "Y units/px" +say gop "頂端顯示" +say xmargin "橫軸邊緣限度" +say ymargin "縱軸邊緣限度" +say height "高" +say_category ArrayProperties +say name "名子" +say n "大小" +say xfrom "橫軸範圍啟" +say xto "橫軸範圍使" +say yfrom "縱軸範圍啟" +say yto "縱軸範圍使" + + +say_category MainWindow +say in "進" +say out "出" +say audio "聲音" +say meters "聲頻錶" +say io_errors "聲頻錯誤" +say console_clear "清空顯示" +say tcl_console "TCL 旨令" +say pd_console "Pd 旨令" +### phase 2 + +say_category Other +say_namespace summary { + say_category IEMGUI + say bng "Bang Box" + say tgl "Toggle Box" + say nbx "Number Box (IEM)" + say hsl "Slider (Horizontal)" + say vsl "Slider (Vertical)" + say hradio "Choice Box (Horizontal)" + say vradio "Choice Box (Vertical)" + say cnv "Canvas (IEM)" + say dropper "Drag-and-Drop Box" + say vu "Vumeter" + + say_category GLUE + say bang "output a bang message" + say float "store and recall a number" + say symbol "store and recall a symbol" + say int "store and recall an integer" + say send "send a message to a named object" + say receive "catch sent messages" + say select "test for matching numbers or symbols" + say route "route messages according to first element" + say pack "make compound messages" + say unpack "get elements of compound messages" + say trigger "sequence and convert messagess" + say spigot "interruptible message connection" + say moses "part a numeric stream" + say until "looping mechanism" + say print "print out messages" + say makefilename "format a symbol with a variable field" + say change "remove repeated numbers from a stream" + say swap "swap two numbers" + say value "shared numeric value" + + say_category TIME + say delay "send a message after a time delay" + say metro "send a message periodically" + say line "send a series of linearly stepped numbers" + say timer "measure time intervals" + say cputime "measure CPU time" + say realtime "measure real time" + say pipe "dynamically growable delay line for numbers" + + say_category MATH + say + "add" + say - "substract" + say * "multiply" + say {/ div} "divide" + say {% mod} "division remainder" + say pow "exponentiate" + say == "equal?" + say != "not equal?" + say > "more than?" + say < "less than?" + say >= "not less than?" + say <= "not more than?" + say & "bitwise conjunction (and)" + say | "bitwise disjunction (or)" + say && "logical conjunction (and)" + say || "logical disjunction (or)" + say mtof "MIDI to Hertz" + say ftom "Hertz to MIDI" + say powtodb "Watts to dB" + say dbtopow "dB to Watts" + say rmstodb "Volts to dB" + say dbtorms "dB to Volts" + say {sin cos tan atan atan2 sqrt} "trigonometry" + say log "Euler logarithm" + say exp "Euler exponential" + say abs "absolute value" + say random "random" + say max "greater of two numbers" + say min "lesser of two numbers" + say clip "force a number into a range" + + say_category MIDI + say {notein ctlin pgmin bendin touchin polytouchin midiin sysexin} "MIDI input" + say {noteout ctlout pgmout bendout touchout polytouchout midiout} "MIDI output" + say makenote "schedule a delayed "note off" message corresponding to a note-on" + say stripnote "strip "note off" messages" + + say_category TABLES + say tabread "read a number from a table" + say tabread4 "read a number from a table, with 4 point interpolation" + say tabwrite "write a number to a table" + say soundfiler "read and write tables to soundfiles" + + say_category MISC + say loadbang "bang on load" + say serial "serial device control for NT only" + say netsend "send messages over the internet" + say netreceive "receive them" + say qlist "message sequencer" + say textfile "file to message converter" + say openpanel ""Open" dialog" + say savepanel ""Save as" dialog" + say bag "set of numbers" + say poly "polyphonic voice allocation" + say {key keyup} "numeric key values from keyboard" + say keyname "symbolic key name" + + say_category "AUDIO MATH" + foreach word {+ - * /} {say $word~ "[say $word] (for signals)"} + say max~ "supremum of signals" + say min~ "infimum of signals" + say clip~ "constrict signal to lie between two bounds" + say q8_rsqrt~ "cheap reciprocal square root (beware -- 8 bits!)" + say q8_sqrt~ "cheap square root (beware -- 8 bits!)" + say wrap~ "wraparound (fractional part, sort of)" + say fft~ "complex forward discrete Fourier transform" + say ifft~ "complex inverse discrete Fourier transform" + say rfft~ "real forward discrete Fourier transform" + say rifft~ "real inverse discrete Fourier transform" + say framp~ "output a ramp for each block" + foreach word {mtof ftom rmstodb dbtorms rmstopow powtorms} { + say $word~ "[say $word] (for signals)" + } +} + +### phase 3 + +say_namespace summary { + say_category "AUDIO GLUE" + say dac~ "audio output" + say adc~ "audio input" + say sig~ "convert numbers to audio signals" + say line~ "generate audio ramps" + say vline~ "deluxe line~" + say threshold~ "detect signal thresholds" + say snapshot~ "sample a signal (convert it back to a number)" + say vsnapshot~ "deluxe snapshot~" + say bang~ "send a bang message after each DSP block" + say samplerate~ "get the sample rate" + say send~ "nonlocal signal connection with fanout" + say receive~ "get signal from send~" + say throw~ "add to a summing bus" + say catch~ "define and read a summing bus" + say block~ "specify block size and overlap" + say switch~ "switch DSP computation on and off" + say readsf~ "soundfile playback from disk" + say writesf~ "record sound to disk" + + say_category "AUDIO OSCILLATORS AND TABLES" + say phasor~ "sawtooth oscillator" + say {cos~ osc~} "cosine oscillator" + say tabwrite~ "write to a table" + say tabplay~ "play back from a table (non-transposing)" + say tabread~ "non-interpolating table read" + say tabread4~ "four-point interpolating table read" + say tabosc4~ "wavetable oscillator" + say tabsend~ "write one block continuously to a table" + say tabreceive~ "read one block continuously from a table" + + say_category "AUDIO FILTERS" + say vcf~ "voltage controlled filter" + say noise~ "white noise generator" + say env~ "envelope follower" + say hip~ "high pass filter" + say lop~ "low pass filter" + say bp~ "band pass filter" + say biquad~ "raw filter" + say samphold~ "sample and hold unit" + say print~ "print out one or more "blocks"" + say rpole~ "raw real-valued one-pole filter" + say rzero~ "raw real-valued one-zero filter" + say rzero_rev~ "[say rzero~] (time-reversed)" + say cpole~ "[say rpole~] (complex-valued)" + say czero~ "[say rzero~] (complex-valued)" + say czero_rev~ "[say rzero_rev~] (complex-valued)" + + say_category "AUDIO DELAY" + say delwrite~ "write to a delay line" + say delread~ "read from a delay line" + say vd~ "read from a delay line at a variable delay time" + + say_category "SUBWINDOWS" + say pd "define a subwindow" + say table "array of numbers in a subwindow" + say inlet "add an inlet to a pd" + say outlet "add an outlet to a pd" + say inlet~ "[say inlet] (for signal)" + say outlet~ "[say outlet] (for signal)" + + say_category "DATA TEMPLATES" + say struct "define a data structure" + say {drawcurve filledcurve} "draw a curve" + say {drawpolygon filledpolygon} "draw a polygon" + say plot "plot an array field" + say drawnumber "print a numeric value" + + say_category "ACCESSING DATA" + say pointer "point to an object belonging to a template" + say get "get numeric fields" + say set "change numeric fields" + say element "get an array element" + say getsize "get the size of an array" + say setsize "change the size of an array" + say append "add an element to a list" + say sublist "get a pointer into a list which is an element of another scalar" + say scalar "draw a scalar on parent" + + say_category "OBSOLETE" + say scope~ "(use tabwrite~ now)" + say namecanvas "" ;# what was this anyway? + say template "(use struct now)" +} + +# phase 4 (pdrc & ddrc) + +say section_audio "聲頻" + say -r "取樣率" + say -audioindev "輸入裝置" + say -audiooutdev "輸出裝置" + say -inchannels "輸入音軌" + say -outchannels "輸出音軌" + say -audiobuf "聲頻緩衝器大小(毫秒)" + say -blocksize "聲頻輸出/入區塊大小(樣框數目)" + say -sleepgrain "空閒至睡眠時間(毫秒)" + say -nodac "停用聲頻輸出" + say -noadc "停用聲頻輸入" + say audio_api_choice "聲頻介面" + say default "內定值" + say -alsa "使用ALSA" + say -jack "使用JACK" + say -mmio "使用MMIO(Windows內定值)" + say -portaudio "使用ASIO(透過Portaudio)" + say -oss "使用OSS" + say -32bit "允許32位元OSS(for RME Hammerfall)" + say {} "內定值" + +say section_midi "MIDI" + say -nomidiin "停用MIDI輸入" + say -nomidiout "停用MIDI輸出" + say -midiindev "Midi輸入裝置名單" + say -midioutdev "Midi輸出裝置名單" + +say section_externals "外加功能" + say -path "尋找路徑" + say -helppath "說明文件路徑" + say -lib "加載功能組" + +say section_gui "使用者介面" + say -nogui "suppress starting the GUI (caution)" + say -guicmd "substitute another GUI program (e.g., rsh)" + say -console "console scrollback lines (0 = disable console)" + say -look "buttonbar icons" + say -statusbar "enable statusbar" + say -font "specify default font size in points" + +say section_other "其它" + say -open "自動開啟檔案" + say -verbose "詳係回報" + say -d "除錯階級" + say -noloadbang "停用 [loadbang]" + say -send "啟動後傳送旨令" + say -listdev "程式開啟時列出聲頻及MIDI裝置名單" + say -realtime "使用即時配給 (須要根權)" + +say section_paths "路徑" + +# phase 4B: ddrc (keyword names not finalized!) + +say section_color "色彩" + say canvas_color "畫布" + say canvasbgedit "畫布背景 (編輯模式)" + say canvasbgrun "畫布背景 (執行模式)" + say object_color "物件" + say viewframe1 "物件外框" + say viewframe2 "物件外框" + say viewframe3 "物件外框" + say viewframe4 "物件反白" + say viewbg "物件背景" + say viewfg "物件前景" + say commentbg "註譯背景" + say commentfg "註譯前景" + say commentframe1 "註譯外框" + say commentframe2 "註譯背景" + say commentframe3 "註譯背景" + say viewselectframe "物件反白外框" + say wire_color "通路" + say wirefg "通路研色" + say wirefg2 "通路反白" + say wiredspfg "聲頻通路" + say futurewiredash "未接通路" + say others_color "其它" + say boxinletfg "輸入點研色" + say boxoutletfg "輸出點研色" + say selrectrect "多選框" +say keys "快速鍵" +say others "其它" +say hairstate "顯示十字器" +say hairsnap "十字器停留物件左上角" +say statusbar "顯示目前狀態" +say buttonbar "顯示按鈕排" +say menubar "顯示清單" +say scrollbar "自動拉霸顯示" +say wirearrow "通路箭頭" +say tooltip "提示" +say insert_object "嵌入物件" +say chain_object "自動連結新物件" +say clear_wires "清除通路" +say auto_wire "移除物件" +say subpatcherize "自動封裝" +say keynav "鍵盤導覽" +say key_nav_up "上移" +say key_nav_up_shift "加入選區" +say key_nav_down "下移" +say key_nav_down_shift "加入選區" +say key_nav_right "右移" +say key_nav_right_shift "加入選區" +say key_nav_left "左移" +say key_nav_left_shift "加入選區" +say key_nav_ioselect "選擇輸出/入點" + +# phase 5A + +say cannot "不能" +say cancel "取消" +say apply "使用" +say ok "好" +say popup_open "打開" +say popup_insert "嵌入物件" +say popup_properties "內容" +say popup_clear_wires "清除通路" +say popup_auto_wire "移除物件" +say popup_help "輔助" +say filter "過濾: " +say how_many_object_classes "%d of %d object classes" +say do_what_i_mean "照我意思做" +say save_changes? "確定存檔?" +say reset "重新設定" +say Courier "Courier (monospaced)" +say Helvetica "Helvetica (sansserif)" +say Times "Times (serif)" +say add "加入" +say up "上移" +say down "下移" +say remove "移除" +say lib_add "add the name you typed to the list" +say lib_up "swap order with previous library" +say lib_down "swap order with next library" +say lib_remove "remove library selected in the list" +say dir_add "add a folder using a file dialog" +say dir_up "swap order with previous folder" +say dir_down "swap order with next folder" +say dir_remove "remove folder selected in the list" +say client_class_tree "客戶端類別樹" +say clipboard_view "閱覽筆記板" +say command_history_view "閱覽旨令歷史記錄" +say event_history_view "閱覽事件歷史記錄" +say keyboard_view "顯示鍵盤" +say abort_server "強迫中止伺服器" +# during/after piksel: + +say auto_apply "自動更新" +say font_preview "預覽:" +say font_preview_2 "ABCDEFGHIJKLMNOPQRSTUVWXYZ\nabcdefghijklmnopqrstuvwxyz\n0123456789" +say font_style "形態:" +say font_bold "粗體" +say font_italic "斜體" +say font_family "字體名:" +say font_size "大小:" +say damn "可惡!" +say preset "預設" +say console "儲存旨令行數" +say language "語言" +say pointer_sense "滑鼠游標敏感度" +say clear_selection "全部反選" +say popup_remove_from_path "移除通路中物件" +say popup_delete_from_path "刪除通路中物件" +say popup_copy_id "考背愛低" +
Modified: branches/pd-devel/0.41.4/src/pd.tk =================================================================== --- branches/pd-devel/0.41.4/src/pd.tk 2008-12-26 09:13:30 UTC (rev 10466) +++ branches/pd-devel/0.41.4/src/pd.tk 2008-12-28 08:37:30 UTC (rev 10467) @@ -18,8 +18,20 @@
# ------------------------------------------------------------------------------ # global variables +# command line options +array set cmd_ops {}
+for {set i 0} {$i < $argc} {incr i} { + global cmd_ops files_to_open + set o [lindex $argv $i] + switch -regexp -- $o { + ^-lang$ {incr i; set cmd_ops(lang) [lindex $argv $i]} + default {lappend files_to_open [lindex $argv $i]} + } +} +if {![info exists cmd_ops(lang)]} {set cmd_ops(lang) "en"}
+puts $cmd_ops(lang) # ------------------------------------------------------------------------------ # init functions
Modified: branches/pd-devel/0.41.4/src/pd_menus.tcl =================================================================== --- branches/pd-devel/0.41.4/src/pd_menus.tcl 2008-12-26 09:13:30 UTC (rev 10466) +++ branches/pd-devel/0.41.4/src/pd_menus.tcl 2008-12-28 08:37:30 UTC (rev 10467) @@ -9,6 +9,7 @@ #namespace import -force ttk::*
package require pd_menucommands +package require pd_say namespace import ::pd_menucommands::*
# TODO figure out Undo/Redo/Cut/Copy/Paste/DSP state changes for menus @@ -35,19 +36,19 @@
proc ::pd_menus::create_file_menu_aqua {rootmenu} { variable accelerator - $rootmenu add command -label "New" -accelerator "$accelerator+N" - $rootmenu add command -label "Open" -accelerator "$accelerator+O" - $rootmenu add cascade -label "Open Recent" + $rootmenu add command -label [say "New"] -accelerator "$accelerator+N" + $rootmenu add command -label [say "Open"] -accelerator "$accelerator+O" + $rootmenu add cascade -label [say "Open Recent"] $rootmenu add separator - $rootmenu add command -label "Close" -accelerator "$accelerator+W" - $rootmenu add command -label "Save" -accelerator "$accelerator+S" - $rootmenu add command -label "Save As..." -accelerator "$accelerator+Shift+S" - # $rootmenu add command -label "Save All" - $rootmenu add command -label "Revert to Saved" + $rootmenu add command -label [say "Close"] -accelerator "$accelerator+W" + $rootmenu add command -label [say "Save"] -accelerator "$accelerator+S" + $rootmenu add command -label [say "Save As..."] -accelerator "$accelerator+Shift+S" + # $rootmenu add command -label [say "Save All"] + $rootmenu add command -label [say "Revert to Saved"] $rootmenu add separator - $rootmenu add command -label "Message" + $rootmenu add command -label [say "Message"] $rootmenu add separator - $rootmenu add command -label "Print..." -accelerator "$accelerator+P" + $rootmenu add command -label [say "Print..."] -accelerator "$accelerator+P" }
# the "Edit", "Put", and "Find" menus do not have cross-platform differences @@ -59,24 +60,24 @@ }
# the "Help" does not have cross-platform differences - + # ------------------------------------------------------------------------------ # menu building functions for UNIX/X11
proc ::pd_menus::create_file_menu_x11 {rootmenu} { variable accelerator - $rootmenu add command -label "New" -accelerator "$accelerator+N" - $rootmenu add command -label "Open" -accelerator "$accelerator+O" + $rootmenu add command -label [say "New"] -accelerator "$accelerator+N" + $rootmenu add command -label [say "Open"] -accelerator "$accelerator+O" $rootmenu add separator - $rootmenu add command -label "Save" -accelerator "$accelerator+S" - $rootmenu add command -label "Save As..." -accelerator "Shift+$accelerator+S" + $rootmenu add command -label [say "Save"] -accelerator "$accelerator+S" + $rootmenu add command -label [say "Save As..."] -accelerator "Shift+$accelerator+S" # $rootmenu add command -label "Revert" $rootmenu add separator - $rootmenu add command -label "Message" -accelerator "$accelerator+M" - $rootmenu add command -label "Print..." -accelerator "$accelerator+P" + $rootmenu add command -label [say "Message"] -accelerator "$accelerator+M" + $rootmenu add command -label [say "Print..."] -accelerator "$accelerator+P" $rootmenu add separator - $rootmenu add command -label "Close" -accelerator "$accelerator+W" - $rootmenu add command -label "Quit" -accelerator "$accelerator+Q" \ + $rootmenu add command -label [say "Close"] -accelerator "$accelerator+W" + $rootmenu add command -label [say "Quit"] -accelerator "$accelerator+Q" \ -command {menu_quit} }
@@ -95,18 +96,18 @@
proc ::pd_menus::create_file_menu_win32 {rootmenu} { variable accelerator - $rootmenu add command -label "New" -accelerator "$accelerator+N" - $rootmenu add command -label "Open" -accelerator "$accelerator+O" + $rootmenu add command -label [say "New"] -accelerator "$accelerator+N" + $rootmenu add command -label [say "Open"] -accelerator "$accelerator+O" $rootmenu add separator - $rootmenu add command -label "Save" -accelerator "$accelerator+S" - $rootmenu add command -label "Save As..." -accelerator "Shift+$accelerator+S" + $rootmenu add command -label [say "Save"] -accelerator "$accelerator+S" + $rootmenu add command -label [say "Save As..."] -accelerator "Shift+$accelerator+S" # $rootmenu add command -label "Revert" $rootmenu add separator - $rootmenu add command -label "Message" -accelerator "$accelerator+M" - $rootmenu add command -label "Print..." -accelerator "$accelerator+P" + $rootmenu add command -label [say "Message"] -accelerator "$accelerator+M" + $rootmenu add command -label [say "Print..."] -accelerator "$accelerator+P" $rootmenu add separator - $rootmenu add command -label "Close" -accelerator "$accelerator+W" - $rootmenu add command -label "Quit" -accelerator "$accelerator+Q" \ + $rootmenu add command -label [say "Close"] -accelerator "$accelerator+W" + $rootmenu add command -label [say "Quit"] -accelerator "$accelerator+Q" \ -command {menu_quit} }
@@ -125,53 +126,53 @@ # menu building functions proc ::pd_menus::create_file_menu {rootmenu name} { [format create_file_menu_%s [tk windowingsystem]] $rootmenu - $rootmenu entryconfigure "New" -command {menu_new} - $rootmenu entryconfigure "Open" -command {menu_open} - $rootmenu entryconfigure "Save" -command {menu_save $name} - $rootmenu entryconfigure "Save As..." -command {menu_saveas $name} + $rootmenu entryconfigure [say "New"] -command {menu_new} + $rootmenu entryconfigure [say "Open"] -command {menu_open} + $rootmenu entryconfigure [say "Save"] -command {menu_save $name} + $rootmenu entryconfigure [say "Save As..."] -command {menu_saveas $name} # $rootmenu entryconfigure "Revert*" -command {menu_revert $name} - $rootmenu entryconfigure "Close" -command {menu_close $name} - $rootmenu entryconfigure "Message" -command {menu_send} - $rootmenu entryconfigure "Print..." -command {menu_print $name} + $rootmenu entryconfigure [say "Close"] -command {menu_close $name} + $rootmenu entryconfigure [say "Message"] -command {menu_send} + $rootmenu entryconfigure [say "Print..."] -command {menu_print $name} }
proc ::pd_menus::create_edit_menu {rootmenu name} { variable accelerator - $rootmenu add command -label "Undo" -accelerator "$accelerator+Z" \ + $rootmenu add command -label [say "Undo"] -accelerator "$accelerator+Z" \ -command {menu_undo $name} - $rootmenu add command -label "Redo" -accelerator "Shift+$accelerator+Z" \ + $rootmenu add command -label [say "Redo"] -accelerator "Shift+$accelerator+Z" \ -command {menu_redo $name} $rootmenu add separator - $rootmenu add command -label "Cut" -accelerator "$accelerator+X" \ + $rootmenu add command -label [say "Cut"] -accelerator "$accelerator+X" \ -command {menu_cut $name} - $rootmenu add command -label "Copy" -accelerator "$accelerator+C" \ + $rootmenu add command -label [say "Copy"] -accelerator "$accelerator+C" \ -command {menu_copy $name} - $rootmenu add command -label "Paste" -accelerator "$accelerator+V" \ + $rootmenu add command -label [say "Paste"] -accelerator "$accelerator+V" \ -command {menu_paste $name} - $rootmenu add command -label "Duplicate" -accelerator "$accelerator+D" \ + $rootmenu add command -label [say "Duplicate"] -accelerator "$accelerator+D" \ -command {menu_duplicate $name} - $rootmenu add command -label "Select All" -accelerator "$accelerator+A" \ + $rootmenu add command -label [say "Select All"] -accelerator "$accelerator+A" \ -command {menu_selectall $name} $rootmenu add separator if {[tk windowingsystem] eq "aqua"} { - $rootmenu add command -label "Text Editor" \ + $rootmenu add command -label [say "Text Editor"] \ -command {menu_texteditor $name} - $rootmenu add command -label "Font" -accelerator "$accelerator+T" \ + $rootmenu add command -label [say "Font"] -accelerator "$accelerator+T" \ -command {menu_font $name} } else { - $rootmenu add command -label "Text Editor" -accelerator "$accelerator+T"\ + $rootmenu add command -label [say "Text Editor"] -accelerator "$accelerator+T"\ -command {menu_texteditor $name} - $rootmenu add command -label "Font" \ + $rootmenu add command -label [say "Font"] \ -command {menu_font $name} } - $rootmenu add command -label "Tidy Up" \ + $rootmenu add command -label [say "Tidy Up"] \ -command {menu_tidyup $name} - $rootmenu add command -label "Toggle Console" -accelerator "Shift+$accelerator+R" \ + $rootmenu add command -label [say "Toggle Console"] -accelerator "Shift+$accelerator+R" \ -command {.controls.switches.console invoke} - $rootmenu add command -label "Clear Console" -accelerator "Shift+$accelerator+L" \ + $rootmenu add command -label [say "Clear Console"] -accelerator "Shift+$accelerator+L" \ -command {menu_clear_console} $rootmenu add separator - $rootmenu add radiobutton -label "Edit Mode" -accelerator "$accelerator+E" \ + $rootmenu add radiobutton -label [say "Edit Mode"] -accelerator "$accelerator+E" \ -indicatoron true -selectcolor grey85 \ -command {menu_editmode $name} \ @@ -182,34 +183,34 @@
proc ::pd_menus::create_put_menu {rootmenu name} { variable accelerator - $rootmenu add command -label "Object" -accelerator "$accelerator+1" \ + $rootmenu add command -label [say "Object"] -accelerator "$accelerator+1" \ -command {menu_object $name 0} - $rootmenu add command -label "Message" -accelerator "$accelerator+2" \ + $rootmenu add command -label [say "Message"] -accelerator "$accelerator+2" \ -command {menu_message $name 0} - $rootmenu add command -label "Number" -accelerator "$accelerator+3" \ + $rootmenu add command -label [say "Number"] -accelerator "$accelerator+3" \ -command {menu_floatatom $name 0} - $rootmenu add command -label "Symbol" -accelerator "$accelerator+4" \ + $rootmenu add command -label [say "Symbol"] -accelerator "$accelerator+4" \ -command {menu_symbolatom $name 0} - $rootmenu add command -label "Comment" -accelerator "$accelerator+5" \ + $rootmenu add command -label [say "Comment"] -accelerator "$accelerator+5" \ -command {menu_comment $name 0} $rootmenu add separator - $rootmenu add command -label "Bang" -accelerator "Shift+$accelerator+B" \ + $rootmenu add command -label [say "Bang"] -accelerator "Shift+$accelerator+B" \ -command {menu_bng $name 0} - $rootmenu add command -label "Toggle" -accelerator "Shift+$accelerator+T" \ + $rootmenu add command -label [say "Toggle"] -accelerator "Shift+$accelerator+T" \ -command {menu_toggle $name 0} - $rootmenu add command -label "Number2" -accelerator "Shift+$accelerator+N" \ + $rootmenu add command -label [say "Number2"] -accelerator "Shift+$accelerator+N" \ -command {menu_numbox $name 0} - $rootmenu add command -label "Vslider" -accelerator "Shift+$accelerator+V" \ + $rootmenu add command -label [say "Vslider"] -accelerator "Shift+$accelerator+V" \ -command {menu_vslider $name 0} - $rootmenu add command -label "Hslider" -accelerator "Shift+$accelerator+H" \ + $rootmenu add command -label [say "Hslider"] -accelerator "Shift+$accelerator+H" \ -command {menu_hslider $name 0} - $rootmenu add command -label "Vradio" -accelerator "Shift+$accelerator+D" \ + $rootmenu add command -label [say "Vradio"] -accelerator "Shift+$accelerator+D" \ -command {menu_vradio $name 0} - $rootmenu add command -label "Hradio" -accelerator "Shift+$accelerator+I" \ + $rootmenu add command -label [say "Hradio"] -accelerator "Shift+$accelerator+I" \ -command {menu_hradio $name 0} - $rootmenu add command -label "VU Meter" -accelerator "Shift+$accelerator+U"\ + $rootmenu add command -label [say "VU Meter"] -accelerator "Shift+$accelerator+U"\ -command {menu_vumeter $name 0} - $rootmenu add command -label "Canvas" -accelerator "Shift+$accelerator+C" \ + $rootmenu add command -label [say "Canvas"] -accelerator "Shift+$accelerator+C" \ -command {menu_mycnv $name 0} $rootmenu add separator $rootmenu add command -label Graph -command {menu_graph $name} @@ -218,37 +219,37 @@
proc ::pd_menus::create_find_menu {rootmenu name} { variable accelerator - $rootmenu add command -label "Find..." -accelerator "$accelerator+F" \ + $rootmenu add command -label [say "Find..."] -accelerator "$accelerator+F" \ -command {menu_findobject $name} - $rootmenu add command -label "Find Again" -accelerator "$accelerator+G" \ + $rootmenu add command -label [say "Find Again"] -accelerator "$accelerator+G" \ -command {menu_findagain $name} - $rootmenu add command -label "Find last error" \ + $rootmenu add command -label [say "Find last error"] \ -command {menu_finderror} }
proc ::pd_menus::create_media_menu {rootmenu name} { variable accelerator - $rootmenu add radiobutton -label "Compute Audio On" -accelerator "$accelerator+/" \ + $rootmenu add radiobutton -label [say "Compute Audio On"] -accelerator "$accelerator+/" \ -command {menu_audio 1} - $rootmenu add radiobutton -label "Compute Audio Off" -accelerator "$accelerator+." \ + $rootmenu add radiobutton -label [say "Compute Audio Off"] -accelerator "$accelerator+." \ -command {menu_audio 0} -indicatoron true $rootmenu add separator - $rootmenu add command -label "Test Audio and MIDI" \ + $rootmenu add command -label [say "Test Audio and MIDI"] \ -command {menu_doc_open doc/7.stuff/tools testtone.pd} - $rootmenu add command -label "Load Meter" \ + $rootmenu add command -label [say "Load Meter"] \ -command {menu_doc_open doc/7.stuff/tools load-meter.pd} }
proc ::pd_menus::create_window_menu {rootmenu name} { variable accelerator if {[tk windowingsystem] eq "aqua"} { - $rootmenu add command -label "Minimize" -command {menu_minimize .} \ + $rootmenu add command -label [say "Minimize"] -command {menu_minimize .} \ -accelerator "$accelerator+M" - $rootmenu add command -label "Zoom" -command {menu_zoom .} + $rootmenu add command -label [say "Zoom"] -command {menu_zoom .} $rootmenu add separator } - $rootmenu add command -label "Parent Window" -state disabled - $rootmenu add command -label "Pd window" -command {menu_raise_console} \ + $rootmenu add command -label [say "Parent Window"] -state disabled + $rootmenu add command -label [say "Pd window"] -command {menu_raise_console} \ -accelerator "$accelerator+R" -state disabled $rootmenu add separator } @@ -265,17 +266,17 @@ }
proc ::pd_menus::create_apple_menu {rootmenu name} { - $rootmenu add command -label "About Pd..." -command \ + $rootmenu add command -label [say "About Pd..."] -command \ {menu_doc_open doc/1.manual 1.introduction.txt} menu $rootmenu.preferences -tearoff 0 $rootmenu add cascade -label "Preferences" -menu $rootmenu.preferences - $rootmenu.preferences add command -label "Path..." \ + $rootmenu.preferences add command -label [say "Path..."] \ -command {pd pd start-path-dialog ;} - $rootmenu.preferences add command -label "Startup..." \ + $rootmenu.preferences add command -label [say "Startup..."] \ -command {pd pd start-startup-dialog ;} - $rootmenu.preferences add command -label "Audio Settings..." \ + $rootmenu.preferences add command -label [say "Audio Settings..."] \ -command {pd pd audio-properties ;} - $rootmenu.preferences add command -label "MIDI settings..." \ + $rootmenu.preferences add command -label [say "MIDI settings..."] \ -command {pd pd midi-properties ;} }
Added: branches/pd-devel/0.41.4/src/pd_say.tcl =================================================================== --- branches/pd-devel/0.41.4/src/pd_say.tcl (rev 0) +++ branches/pd-devel/0.41.4/src/pd_say.tcl 2008-12-28 08:37:30 UTC (rev 10467) @@ -0,0 +1,12 @@ +#!/usr/bin/wish +# For information on usage and redistribution, and for a DISCLAIMER OF ALL +# WARRANTIES, see the file, "LICENSE.txt," in this distribution. +# Copyright (c) 1997-2009 Miller Puckette. + +# say names in localized language + +package provide pd_say 0.1 + +proc say {name} { + return "$name" +} \ No newline at end of file
Modified: branches/pd-devel/0.41.4/src/pkgIndex.tcl =================================================================== --- branches/pd-devel/0.41.4/src/pkgIndex.tcl 2008-12-26 09:13:30 UTC (rev 10466) +++ branches/pd-devel/0.41.4/src/pkgIndex.tcl 2008-12-28 08:37:30 UTC (rev 10467) @@ -12,3 +12,4 @@ package ifneeded pd_iemgui 0.1 [list source [file join $dir pd_iemgui.tcl]] package ifneeded pd_menucommands 0.1 [list source [file join $dir pd_menucommands.tcl]] package ifneeded pd_menus 0.1 [list source [file join $dir pd_menus.tcl]] +package ifneeded pd_say 0.1 [list source [file join $dir pd_say.tcl]]
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.