Results 1 to 20 of 22

Thread: Sorting a QVector

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #19
    Join Date
    Feb 2006
    Location
    Romania
    Posts
    2,744
    Thanks
    8
    Thanked 541 Times in 521 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Sorting a QVector

    It is qSort, with capital "S".

    Or, if not, try:
    Qt Code:
    1. qSort(list.begin(), list.end(), qLess<int>());
    To copy to clipboard, switch view to plain text mode 

    Regards

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

    arjunasd (11th August 2007)

Similar Threads

  1. Model sorting vs. selection
    By VlJE in forum Qt Programming
    Replies: 2
    Last Post: 25th October 2006, 16:46
  2. QVector problem
    By kingslee in forum Qt Programming
    Replies: 5
    Last Post: 19th October 2006, 10:42
  3. Column Sorting
    By sumsin in forum Qt Programming
    Replies: 1
    Last Post: 16th June 2006, 07:48
  4. QT4: Sorting in QTreeWidget (subclass)
    By Michiel in forum Qt Programming
    Replies: 21
    Last Post: 29th March 2006, 18:08
  5. [QT4] QTreeView, QAbstractItemModel and sorting
    By KShots in forum Qt Programming
    Replies: 3
    Last Post: 24th March 2006, 20:16

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.