python - Subsequent tabs being closed in pyqt -


i trying close tab when users presses close tab button. code should that:

self.tab_widget.addtab(text, tabname) self.tab_widget.settabsclosable(1) self.tab_widget.tabcloserequested.connect(self.tab_widget.removetab) 

it works, when close tab before other tab(s) closes out of them after it, , not sure why. help?

oh... figured out why happening. had code removes tabs code creates them , guess doing multiple connects getting rid of more 1 tab.


Comments

Popular posts from this blog

ios - UICollectionView Self Sizing Cells with Auto Layout -

node.js - ldapjs - write after end error -

DOM Manipulation in Wordpress (and elsewhere) using php -