Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Getting tkTable column width in pixels 1

Status
Not open for further replies.

firelex

Programmer
Jan 10, 2002
118
DE
Hello all!
Has anybody an idea how could I get tkTable to give as answer for such command :
set width [$table width 0]
the width of a column in pixels? The only thing I´ve managed to get is column width, but in characters.
Thanks
 
The only way I could get $tblname width $x to give me back pixels was to have first specified a width for that column in pixels. Bob Rashkin
rrashkin@csc.com
 
Hello, Bong!
I´ve found a way for that without setting a width for the column in pixels first :
This command '$tblname bbox first ?last?' returns the bounding box for the specified cell (or range of cells) as a 4-tuple of x,y,width and height in pixels. So just the thing I´ve needed.
[pc]
 
Excellent! Thanks for the info. Bob Rashkin
rrashkin@csc.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top