Results 1 to 3 of 3

Thread: QTreeView cell as table

  1. #1
    Join Date
    Jan 2006
    Location
    Sta. Eugènia de Berga (Vic - Barcelona - Spain)
    Posts
    869
    Thanks
    69
    Thanked 59 Times in 57 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default QTreeView cell as table

    Hi,

    I have a model that is show in a QTreeView.
    Can I show a table as a QTreeView cell?

    Representation:
    Name Value
    Parameter1 1
    Parameter2 Table
    Parameter3 10

    It's possible to do this?

    Thanks,
    Òscar Llarch i Galán

  2. #2
    Join Date
    Oct 2006
    Location
    New Delhi, India
    Posts
    2,467
    Thanks
    8
    Thanked 334 Times in 317 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QTreeView cell as table

    I guess with delegates you can do that. You could use a QTextDocument to render the table onto the delegates painter. And yea table can be created with simple html. Hope this solution works for u

  3. #3
    Join Date
    Jan 2006
    Location
    Sta. Eugènia de Berga (Vic - Barcelona - Spain)
    Posts
    869
    Thanks
    69
    Thanked 59 Times in 57 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: QTreeView cell as table

    Hi,

    I have created my delegate derived from QItemDelegate. Then I need to derivate my delegate from QAbstractItemDelegat, right? And could then be possible to paint the table as a QTableWidget?

    Thanks,
    Òscar Llarch i Galán

Similar Threads

  1. QTreeView: How to center a checkbox in a cell
    By chezifresh in forum Qt Programming
    Replies: 3
    Last Post: 19th December 2008, 12:11
  2. Making Table cell as a combobox?
    By kaushal_gaurav in forum Qt Programming
    Replies: 9
    Last Post: 1st August 2008, 12:04
  3. Replies: 4
    Last Post: 4th February 2008, 06:16
  4. Replies: 11
    Last Post: 7th September 2006, 23:15
  5. Highlighting the border of cell in Table
    By ankurjain in forum Qt Programming
    Replies: 8
    Last Post: 21st March 2006, 08:20

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.