Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. How do you add a widget to a table cell in Qt Designer?

How do you add a widget to a table cell in Qt Designer?

Scheduled Pinned Locked Moved Qt Creator and other tools
3 Posts 3 Posters 5.6k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Offline
    L Offline
    Larnie
    wrote on last edited by
    #1

    Apologies if this has been asked before, but is there a way of adding a widget such as a combo box to a cell in a table widget using Qt Designer?

    I've found references to doing it in code, but is it possible through the interface?

    1 Reply Last reply
    0
    • O Offline
      O Offline
      octal
      wrote on last edited by
      #2

      bq. I’ve found references to doing it in code, but is it possible through the interface?

      Unfortunately, I'm afraid you will have to do it from your source code.

      Furthermore, depending on your use case, you might consider using a "QStyledItemDelegate":http://doc.qt.nokia.com/latest/qstyleditemdelegate.html to provide your combobox.

      1 Reply Last reply
      0
      • G Offline
        G Offline
        goetz
        wrote on last edited by
        #3

        Have a look at the "Combo Boxes in Item Views":http://developer.qt.nokia.com/wiki/Combo_Boxes_in_Item_Views wiki article for an example on how to achieve this.

        http://www.catb.org/~esr/faqs/smart-questions.html

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved