QToolbox remove item



  • Two questions in one I guess,

    I have a QToolbox and in every item in the toolbox I have a QTextEdit.
    I would like to remove one item from the toolbox and delete this items QTextEdit from memory.

    I have tried toolBox.removeItem(indexNum) but nothing happens?

    To delete the QTextEdit I have tried close() and destroy() but somehow its still there eventhough its not visible.

    Thank you



  • Try first hiding it ( setHidden(true)) and then remove it.
    Or try to re-render the window.



  • Thanks Ant Farmer, with the textEdit it worked fine with setHidden.
    removeItem(index) on toolbox also works.

    Cheers



  • And then just delete the item.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.