
Adding a button to a canv
In a message on 25 May, wrote :
f5> Hi, The problem I seem to be having is this:
f5> I have a canvas widget in which i have drawn many lines, etc. I want
f5> to place a button widget onto the canvas at a certain position. Any idea
f5> on how to place this button, i've tried the -side, and -anchor options,
f5> but they do not do what I require. Is there any way to position
f5> a widget in a canvas with coordinates (x and y positioning)? Thanks in
f5> advance.
f5>
f5> Reg Sherwood
f5>
canvas .c
pack .c
button .c.b
.c create window $x $y -anchor nw -window .c.b
Robert
PS: It is also posible to put text on the canvas, given it a non-flat
relief and give it button-like bindings and make is behave like to
button. This latter has the advantage of being printable (.c postscript ...).
RPH
---
t ATP/Linux 1.42 t OS-9/68000 -- The only *real* operating system.
--
Robert Heller ||BIX: locks.hill.bbs
http://www.*-*-*.com/ ~heller ||FidoNet: 1:321/153
http://www.*-*-*.com/ ;/\CompuServe: 71450,3432