Results 1 to 3 of 3

Thread: multiselection in a tableview with CTRL Button

  1. #1
    Join Date
    May 2012
    Posts
    33
    Thanks
    3
    Qt products
    Qt4
    Platforms
    Windows

    Default multiselection in a tableview with CTRL Button

    hi all... i have a tableview in mu Qt Gui application... i wana let user to select multirows of table with pressing down CTRL button and click on them.... what shall i do?

  2. #2
    Join Date
    Jul 2012
    Posts
    2
    Qt products
    Qt3 Qt4 Qt/Embedded Qt Jambi PyQt3 PyQt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: multiselection in a tableview with CTRL Button

    Can you try using the below properties for ur TableView:
    <ur TableView Object Name> ->setSelectionMode(QAbstractItemView::MultiSelection );
    <ur TableView Object Name> ->setSelectionBehavior(QAbstractItemView::SelectRows );

  3. #3
    Join Date
    May 2012
    Posts
    33
    Thanks
    3
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: multiselection in a tableview with CTRL Button

    thats right... but by this code the default mode of table would be multiselect.. i do not need this... read my question again..

Similar Threads

  1. QTreeView multiselection
    By mentalmushroom in forum Qt Programming
    Replies: 0
    Last Post: 14th September 2011, 09:52
  2. QTableView multiselection with shift
    By swrer in forum Newbie
    Replies: 3
    Last Post: 11th July 2010, 10:10
  3. QListWidget multiselection indexes
    By OverTheOCean in forum Newbie
    Replies: 2
    Last Post: 2nd June 2010, 06:13
  4. QListView multiSelection
    By cristiano in forum Qt Programming
    Replies: 3
    Last Post: 19th December 2006, 23:41
  5. Rubberband painting on multiselection in a list view
    By SkripT in forum Qt Programming
    Replies: 10
    Last Post: 19th March 2006, 11:13

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.