Results 1 to 2 of 2

Thread: QHeaderView

  1. #1
    Join Date
    Sep 2007
    Posts
    99
    Thanks
    8
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Red face QHeaderView

    HI!

    Is there any way in Qt designer how to set the number of QTableView columns and rows and then set the HeaderViews to particular columns of QTableView ?
    Or it has to be done manually ->> in actual source code ?

    I mean, I create a main window, put QTableView into it and I want to set it to have 4 columns and let's say 10 rows. And set and display QHeadViews to each of the columns.

    Thanks for help!

  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: QHeaderView

    The view is completely controlled by the model, so you have to do everything on the model side. Alternatively you can use a convenience class - QTableWidget and you'll be able to edit rows and columns from within Designer in exchange for flexibility.

Similar Threads

  1. Replies: 2
    Last Post: 14th August 2007, 15:16
  2. QHeaderView as a banner
    By mclark in forum Qt Programming
    Replies: 1
    Last Post: 21st March 2007, 19:28
  3. Renumbering Row Headers of QHeaderView
    By mclark in forum Newbie
    Replies: 4
    Last Post: 11th September 2006, 15:04
  4. [itemView] QHeaderView lose mapping at column insertion
    By lauranger in forum Qt Programming
    Replies: 1
    Last Post: 16th August 2006, 18:18
  5. subclassing QHeaderView
    By chemstar in forum Qt Programming
    Replies: 7
    Last Post: 22nd May 2006, 12:34

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.