Results 1 to 8 of 8

Thread: QTable Column width supporting fonts

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #6
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,376
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Thanks
    4
    Thanked 5,019 Times in 4,795 Posts
    Wiki edits
    10

    Default Re: QTable Column width supporting fonts

    Hmm.. as far as I know "m" is the widest character. Remember that cells have margins, so if you want to display 7 characters, you need fm.width("m")*7 + 2*margin. But before you do that, take a look at QHeader::setStretchEnabled - if you enable stretch for all columns, they will scale when you resize the table.

  2. The following user says thank you to wysota for this useful post:

    kommu (27th December 2007)

Similar Threads

  1. QTable column stretchable with minimum Width
    By sunil.thaha in forum Qt Programming
    Replies: 0
    Last Post: 24th April 2006, 14:17

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.