diff options
author | Hans-Christoph Steiner <eighthave@users.sourceforge.net> | 2010-11-30 21:18:47 +0000 |
---|---|---|
committer | Hans-Christoph Steiner <eighthave@users.sourceforge.net> | 2010-11-30 21:18:47 +0000 |
commit | e58f6b3236f51c06e53c407a46d41f5e898c3b3c (patch) | |
tree | 0f591563a53ca78869729ec022f76de692306885 /add_menubar_to_popup_menu-plugin.tcl |
added the simple plugins from the pd-gui-rewrite/0.43/startup branchsvn2git-root
svn path=/trunk/scripts/guiplugins/simple_examples/; revision=14540
Diffstat (limited to 'add_menubar_to_popup_menu-plugin.tcl')
-rw-r--r-- | add_menubar_to_popup_menu-plugin.tcl | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/add_menubar_to_popup_menu-plugin.tcl b/add_menubar_to_popup_menu-plugin.tcl new file mode 100644 index 0000000..ee8149b --- /dev/null +++ b/add_menubar_to_popup_menu-plugin.tcl @@ -0,0 +1,17 @@ +# this scriptlet removes the menubars from all canvas windows. You could also +# create your own custom menu and add it to the canvas windows. + +# TODO ::pd_menus::update_window_menu expects to find ::patch_menubar not "" + +# on Mac OS X, no windows have menubars, so no need to remove for 'aqua' +if {$::windowingsystem ne "aqua"} { + set ::patch_menubar "" +} + +set menulist "file edit put find media window help" +.popup add separator +foreach mymenu $menulist { + .menubar.$mymenu clone .popup.$mymenu normal + .popup add cascade -label [_ [string totitle $mymenu]] \ + -menu .popup.$mymenu +} |