Results 1 to 4 of 4

Thread: QTable widget works slow :(

  1. #1
    Join Date
    Mar 2007
    Location
    Ukraine, Odessa
    Posts
    140
    Thanks
    15
    Thanked 11 Times in 10 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Red face QTable widget works slow :(

    Hello everyone

    Recently a problem occurred in my application. I'm using QTableWidget to display information about downloads. My QTableWidget has 8 columns and each row has some data displayed as QTableWidgetItem and some data displayed as QLabel. The problem is that when the number of rows exceeds 20 scrolling is soooo slow
    I've provided a screenshot of my tablewidget
    Attached Images Attached Images
    • File Type: jpg 1.jpg (54.3 KB, 24 views)
    C++ & AMD forever

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: QTable widget works slow :(

    Does the "progress" column contain QProgressBar widgets? If so, they are the cause of slowdowns.

    Read this: http://www.qtcentre.org/forum/f-qt-p...item-2330.html

  3. #3
    Join Date
    Mar 2007
    Location
    Ukraine, Odessa
    Posts
    140
    Thanks
    15
    Thanked 11 Times in 10 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: QTable widget works slow :(

    Thanks for reply it seems to be true but not only QProgressBar causes lags but QLabels also because when I removed them from my code app started to run faster. Anyway could you advise me what can I do about it ?
    C++ & AMD forever

  4. #4
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: QTable widget works slow :(

    Every widget put inside the view will cause lags. It can all be avoided using a custom delegate like the thread I gave you suggests.

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

    THRESHE (27th February 2008)

Similar Threads

  1. Tricky problem with ARGB widget / UpdateLayeredWindow
    By nooky59 in forum Qt Programming
    Replies: 3
    Last Post: 21st February 2008, 10:35
  2. Custom widget - Only works in Designer
    By Darhuuk in forum Qt Tools
    Replies: 6
    Last Post: 8th January 2008, 00:46

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.