[fxruby-users] FXTable::fitColumnsToContents
David Toll
toll at us.ibm.com
Tue May 20 10:05:28 EDT 2008
On May 19, 2008, at 9:43 PM, Lyle Johnson wrote:
Wait, I've got it now. The spacing's different because it's a header
item and not a table item. Here's the correct formula:
hw =
columnHeader.font.getTextWidth(columnHeader.getItemText(c)) +
2*columnHeader.borderWidth +
columnHeader.padLeft +
columnHeader.padRight
That looks right here, for the font that I'm testing with. Let me know
what you think!
That does indeed work as I would expect. Thank you.
Does this mean there is a bug in the "standard" version of
fitColumnstoContents - i.e. should the standard version be changed to this
new version?
Dave
____________________________________________________________
David C. Toll, Research Staff Member, Secure Embedded Systems
IBM T. J. Watson Research Center, 19 Skyline Drive, Hawthorne NY 10532
Phone: 914-784-7019 (t/l 863) Fax: 914-784-6205 (t/l 863) email:
toll at us.ibm.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/fxruby-users/attachments/20080520/2f69ca90/attachment-0001.html>
More information about the fxruby-users
mailing list