Results 1 to 2 of 2

Thread: Qt 5.13 QTableWidget How to select/deselect all rows

  1. #1
    Join Date
    Jun 2007
    Location
    Louisiana
    Posts
    77
    Thanks
    1
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Qt 5.13 QTableWidget How to select/deselect all rows

    I have a project using the QTableWidget as the data display.

    My question / issue is how to select all rows without iterating through each to select one at a time. Deselect of all rows is the same problem.

    Is there a way to do this efficiently or must i code it into a loop moving through each row one at a time to select or deselect?

    Any help is appreciated.

  2. #2
    Join Date
    Jul 2008
    Location
    Germany
    Posts
    514
    Thanks
    12
    Thanked 76 Times in 74 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Qt 5.13 QTableWidget How to select/deselect all rows

    Hi, QTableWidget::setRangeSelected() looks like it does what you want.

    Ginsengelf

Similar Threads

  1. QTreeWidgetItem select different rows?
    By SirJonas in forum Newbie
    Replies: 2
    Last Post: 21st February 2017, 23:38
  2. Replies: 3
    Last Post: 5th April 2016, 09:23
  3. QTableView: Select multiple rows?
    By realdarkman71 in forum Newbie
    Replies: 2
    Last Post: 9th December 2010, 21:36
  4. QTreeView and multi-select of rows
    By QPlace in forum Qt Programming
    Replies: 1
    Last Post: 27th October 2008, 02:32
  5. QTableWidget - Select multiple rows.
    By wally in forum Qt Programming
    Replies: 2
    Last Post: 21st October 2008, 17:15

Tags for this Thread

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.