Tkinter measurements

John Velman velman at cox.net
Mon Sep 27 19:19:13 EDT 2004


I want to draw a box around a short piece of text in canvas (one line
text).  I know how to do it if I place the text on the canvas first,then
draw the box around it. 

Is there a way to find out the dimensions of the text bounding box before
drawing it?

Also, is there a method for converting from pixels to inches or inches to
pixels (for canvas)?


Thanks,

John Velman



More information about the Python-list mailing list