[GRASS5] Tcl/Tk Disable Tear-off?

Glynn Clements glynn.clements at virgin.net
Tue Oct 8 10:13:41 EDT 2002


Jeshua Lacock wrote:

> I would like to disable the "Tear-off" option from the menu if at all 
> possible. Does anyone know how disable it?

This seems to work:

--- src/tcltkgrass/main/gui.tcl~	Thu Apr 11 09:45:35 2002
+++ src/tcltkgrass/main/gui.tcl	Tue Oct  8 15:10:51 2002
@@ -142,7 +142,7 @@
                 if {$initial} {
                     set menupath $path.mb$j.m
                     menubutton $path.mb$j -text $label -menu $menupath
-                    menu $menupath
+                    menu $menupath -tearoff 0
                     pack $path.mb$j -side left -expand yes
                     bindtags $path.mb$j [list $path.mb$j Menubutton balloon . all]
                     set balloonHelp($path.mb$j) $comment

-- 
Glynn Clements <glynn.clements at virgin.net>




More information about the grass-dev mailing list