[PD-cvs] SF.net SVN: pure-data:[10728] branches/pd-devel/0.41.4/src/pd_menucommands. tcl
eighthave at users.sourceforge.net
eighthave at users.sourceforge.net
Tue Feb 3 15:24:32 CET 2009
Revision: 10728
http://pure-data.svn.sourceforge.net/pure-data/?rev=10728&view=rev
Author: eighthave
Date: 2009-02-03 14:24:31 +0000 (Tue, 03 Feb 2009)
Log Message:
-----------
the find panel is now in find_panel.tcl
Modified Paths:
--------------
branches/pd-devel/0.41.4/src/pd_menucommands.tcl
Modified: branches/pd-devel/0.41.4/src/pd_menucommands.tcl
===================================================================
--- branches/pd-devel/0.41.4/src/pd_menucommands.tcl 2009-02-03 14:05:29 UTC (rev 10727)
+++ branches/pd-devel/0.41.4/src/pd_menucommands.tcl 2009-02-03 14:24:31 UTC (rev 10728)
@@ -69,72 +69,6 @@
}
-# ------------------------------------------------------------------------------
-# find panel
-
-proc find_ok {mytoplevel} {
- # find will be on top, so use the previous window that was on top
- set search_window [lindex [wm stackorder .] end-1]
- if {$search_window eq "."} {
- puts "search pd window not implemented yet"
- } else {
- puts "search_window $search_window"
- set find_string [.find.entry get]
- if {$find_string ne ""} {
- pdsend "$search_window find $find_string"
- }
- }
-}
-
-proc find_cancel {mytoplevel} {
- wm withdraw .find
-}
-
-proc ::pd_menucommands::menu_find_panel {mytoplevel} {
- if {[winfo exists .find]} {
- wm deiconify .find
- raise .find
- } else {
- # TODO figure out findagain
- # TODO make targetlabel into a popup menu
- toplevel .find
- wm title .find [_ "Find"]
- wm geometry .find =475x125+150+150
- wm resizable .find 0 0
- if {[catch {wm attributes .find -topmost}]} {puts stderr ".find -topmost failed"}
- .find configure -background $::panel_background
- ::pd_bindings::panel_bindings .find "find"
-
- frame .find.frame -background $::panel_background
- pack .find.frame -side top -fill x -pady 7
- label .find.frame.searchin -text [_ "Search in:"] -background $::panel_background
- label .find.frame.targetlabel -background $::panel_background \
- -text [wm title $mytoplevel]
- label .find.frame.for -background $::panel_background -text [_ "for:"]
- pack .find.frame.searchin .find.frame.targetlabel .find.frame.for -side left
- entry .find.entry -width 54 -font 18 -relief sunken \
- -highlightthickness 3 -highlightcolor blue \
- -highlightbackground $::panel_background
- focus .find.entry
- pack .find.entry -side top -padx 10
-
- frame .find.buttonframe -background yellow
- button .find.button -text [_ "Find"] -default active -width 9 \
- -highlightbackground $::panel_background -command "find_ok $mytoplevel"
- if {$::windowingsystem eq "x11"} {
- button .find.close -text [_ "Close"] -default normal -width 9 \
- -highlightbackground $::panel_background -command "find_cancel $mytoplevel"
- pack .find.buttonframe .find.button .find.close -side right -padx 10 -pady 15
- } else {
- pack .find.buttonframe .find.button -side right -padx 10 -pady 15
- }
- }
- # TODO this panel should probably receive <FocusIn> events so that it will
- # find in which ever window has focus then "OK' is clicked. It will need
- # to filter out the Pd window, unless someone implements searching in the
- # console text. hmm that would be nice!
-}
-
proc ::pd_menucommands::menu_font_panel {mytoplevel} {
if {[winfo exists .font]} {
wm deiconify .font
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Pd-cvs
mailing list