Tk Source Code

Artifact [cdb977c8]
Login

Artifact cdb977c8090610a016fb8c00e359b3d566d2bfb0:

Attachment "container.tcl" to ticket [1144186f] added by kjnash 2005-02-19 09:09:01.
#!/usr/local/ActiveTcl/bin/wish

# Subject: -use -container embedded windows menu problems

# When a wish toplevel is embedded in a frame or toplevel of another wish app that has been identified as a container, there are problems with menus.

# same whether the container is a frame or a toplevel

# X11:
# the menu bar is there, but the menus pop up in the wrong place (a bit too low on the screen)
# Tested in Fedora Core 3
# Same with 3 different window managers: KDE 3.3.1-2.4.FC3, Gnome (metacity 2.8.6-2), or XFCE (xfwm4-4.0.6-1)
# Same with both current versions of ActiveTcl: 8.4.9.0, 8.5.0 beta3 (8.5a2)

# Windows - a different problem
# Windows XP Home (SP2): the menu bar does not appear at all.


# use the widget demo as the embedded application
# no need to run any of the demos - look at the menus of the root window


if 0 {
	frame .f -container true
	set frameID [winfo id .f]
	pack .f
} else {
	toplevel .f -container true
	set frameID [winfo id .f]
}

exec /usr/local/ActiveTcl/bin/wish $tk_library/../../demos/Tk/widget.tcl -use $frameID &

# Windows
#exec wish $tk_library/../../demos/Tk/widget.tcl -use $frameID &